Reputation: 1526
In our office we have a Linux server with a shared drive. On this shared drive we have our client web projects and we all work directly in those files.
Now I am trying to get a project into git (at Bitbucket). When I do it from the command prompt (Windows) using these commands:
W:\projectfolder $ git init
W:\projectfolder $ git remote add origin https://username:[email protected]/mediafolder/rep.git
W:\projectfolder $ git add --all
W:\projectfolder $ git commit -m "Initial commit"
W:\projectfolder $ git push -u origin master
When I reopen the project on my PC, make changes and commit, it only commits the files that were changed, which is correct.
Now my coworker opens the folder, makes changes to some files, he has to commit everything all over again, which of course gives errors as there were no changes to most files
Does this have to do with access rights to some files?
We could of course clone the project to the local dev environment, but as we have hundreds of projects, it would be overkill to have them all locally installed or every time we need to make one small change have to clone first
Your help will be much appreciated
Upvotes: 0
Views: 93
Reputation: 67574
We could of course clone the project to the local dev environment
That's exactly how git works, it's not meant to store the repository in a shared network location you directly access.
Upvotes: 2