Closed vlcinsky closed 11 years ago
I've made explicit in the README that it only synchronise git repositories for now.
The current process for git happens in https://github.com/Gautier/bitbucket-sync/blob/master/bitbucket_sync/main.py#L31 and uses commands that do the following :
Would you know equivalent commands for mercurial?
Gautier, you are like heap of rolling stones. Nice.
I will check how to do that in Mercurial.
regarding README - if you rename the file to README.rst, it will be nicely rendered as reStructuredText.
To make bare Mercurial repository:
$ hg clone -U ssh://hg@bitbucket.org/vlcinsky/dalimil
or to send it to directory with another name
$ hg clone -U ssh://hg@bitbucket.org/vlcinsky/dalimil alternative-directory-for-repo
or even create new subdirectory by this:
$ hg clone -U ssh://hg@bitbucket.org/vlcinsky/dalimil vlcinsky/dalimil-repo
Just use the -U to prevent creation of working copy.
git uses extensin ".git" to denominate bare repo, I am not aware of such a convention for Mercurial, but I am not using Mercurial for more then a year, so there might be one. One could easily pick similar rule to git and use an extension ".hg"
I hope, I understood your intention of synced repository properly.
"vlcinsky" is my "owner" directory and in there is repository "dalimil"
"vlcinsky" is direct subdirectory of my current one.
$ hg -R "vlcinsky/dalimil" verify -q
It does not output anything, if all is fine.
If there is a problem, there is some content written to stderr.
To download all changes from remote repository to local one, call:
$ hg -R vlcinsky/dalimil pull -q
It does not attempt to do anything with working copy.
I hope this concludes all the activities, you are currently performing for git and which would be nice to see done also for mercurial.
Support for mercurial is now added.
Thanks for all your suggestions and work today. I hope the tool will work well for you.
It was pleasure. Now I see, the tool is really getting into shape and will soon become part of our ecosystem. And the speed you react is awesome. My favorite Pieter Hintjens (ZeroMQ guy) is proposing in his End of Stable Releases development in style "challenge - resolve", or in detail: "C4 asserts that the optimal design for a software development team is two halves, one that sets challenges, and one that solves them.".
As I see, it works well.
If you like, I may update README.rst
Confirmed, that Mercurial support works well and git one stay working.
It took me a while, to get all initially cloned, but this is due to my a bit limited connectivity (4 Mbps) and number of repositories (66).
Second run - which was only checking for changes, went very quickly (seems like 3-5 repositories checked per second).
Did not test real update of remote repository, this may come some day later.
So - now I have the most complete backup of my source code I have ever had in last few years.
Currently, no text indicates, that only git repositories are synced.
Either explicitly say, only git repos are synced (this is currently fine with me), or add ability to sync also Mercurial ones (it seems relatively easy to do and would be nicer).