Yes. Mercurial sucks.
If you were considering going deeper into it. Forget it.
Does any high-end super glorious system give you a suggestion to delete all your modifications silently? Yes. Mercurial.
After one day of hard work I want to commit.
hg commit -m 'Great job'
then great mercurial suggests:
abort: unresolved merge conflicts (see hg resolve)
Yes. It's telling you to run hg resolve. And if you do it with option -all you will loose all fucking changes since last update in a local directory.
Fuck this system.
If you really want to know how to clone to the remote repo - read below.
Say you have /home/joe/my_source direcory where you have your code and you want to make a new remote repository. You have to have ssh access to the remote repository.
cd /home/joe/my_source
hg init #create new local repo
hg add [files you want to add]
hg commit -m 'initial changeset' #commit initial changeset
hg push #push changes to repo
You migh want to use hg push ssh://repo@myrepo.com:22//home/repo/my_remote_source if you get "abort: repository default-push not found!" error. I don't know how to fix it yet.
Cloning:
cd /home/joe
hg clone my_source ssh://repo@myrepo.com:22//home/repo/my_remote_source
A note for cloning. Normally you clone from remote repo to local directory. My example is opposite. If you want to import repository to local directory then look elsewhere (it's easy).
The command above creates my_remote_source directory on the server and clones the local repository (from /home/joe/my_source) to myrepo.com.
'//' means absolute path. If you use '/' after port number it will be relative to home directory.
Now you have to:
ssh repo@myrepo.com
cd my_remote_source
hg update
That's done you should have your repo cloned. There is a way to make the last step automatic
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment