version control - Untrack files without removing from remote repository -
in our company, started using mercurial , facing following problem:
we have files in remote repository changed each developer add local configuration these files must never changed in remote repository.
is there way tell mercurial stop tracking files locally without making change file on remote repository?
we tried hg forget <file>
understand, remove file remote repository.
we tried adding files .hgignore
file, somehow files not being ignored, guess mercurial because files being tracked.
so far, ignoring files when perform commit , use shelve
maintain , restore our local changes after update, it's starting tedious task.
thanks in advance help.
edit: although didn't fix wanted to, accepted answer best approach. our problem result of bad design.
if file want unchanged is, example, config.cfg
, check in config_template.cfg
, forget config.cfg
if tracked, , add config.cfg
ignore list. then, build rule can create config.cfg
template if not exist.
a user have starting config.cfg can customize without checking in.
Comments
Post a Comment