I'm in this situation:
First of all I just started to use mercurial. I've a server where there's a my django project.
I want to clone repository from the project dir on server in my local computer.
I've done this:
user@host> cd myproject
user@host> hg init
user@host> hg add
user@host> hg commit -m "Added initial files."
I've cloned the repo with hg clone ssh://user@host//path/to/project
. And it's ok, on my computer I've all files that I've on the server.
Now, I want to edit settings.py
for setting local environment (database engine and other stuff), but I don't want to update the settings.py
on the server. And after the edit, hg status
returns me M settings.py
. Even if I set echo 'settings.py' > .hgignore
in my local repo, it doesn't work. The same for the directories static
, media
and the database my_database
in the working directory. How can I set mercurial for NOT update and commit in the server?
I want to work either on my computer and on the server and get all two repo always synchronized.
Could someone kindly explain me what should I do? I'm a bit confused.
Thank you!