I have files I move around between several different environments, and in 
each environment I have a config file (web.config) that is unique to each 

I make changes on my machine, push them to a repository, move to a 
development machine and "pull" them from the repository, then move them to 
to a test machine and "pull" them from the repository, etc.

Through some trial and error I figured out that "most of the time" if I put 
my web.config into my .gitignore file everything works fine, but not always.

Right now I'm spending my afternoon trying to figure out why whenever I 
checkout the "master" branch it deletes my web.config file. It happens like 
this. I will have my web.config file in my directory and then checkout a 
branch into that directory (e.g. git checkout new-search) and everything is 
fine. If I switch to another branch (e.g. git checkout fix-search) 
everything is fine as well. But when I check out the master branch (e.g. 
git checkout master) it deletes my web.config file. 

Why is it deleting my config file and more importantly, how can I get it to 
stop doing that so that I can spend my time working on code and not fussing 
with git?


You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To view this discussion on the web visit 
To post to this group, send email to git-users@googlegroups.com.
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to