[Pkg-ime-devel] Unofficial mirror of pkg-ime Git repositories

Aron Xu happyaron.xu at gmail.com
Mon Jan 30 23:42:25 UTC 2012


On Tue, Jan 31, 2012 at 06:48, Yao Wei <medicalwei at gmail.com> wrote:
> Is it possible to two-way sync with alioth? Or, should I fork from pkg-ime
> instead if I need a temporary workspace when alioth is down?
>

Two-way sync is not possible because the script can't handle merges
when the two copies have conflicts. And as it is an unofficial mirror,
development should happen at the copy on Alioth whenever it's online.

The primary idea of making this mirror is having a backup of those
repositories, in case you don't have them locally. Thanks to Git's
power, we are enabled to do much more, :)

By saying such, you are free to choose what to do when Alioth isn't
working, it's quite easy to keep several remotes in your local copy of
repository. For example, you have made a clone from Alioth, and your
normal development happens at this repository.

Note: this is only one of the possible workflows, it might not be of
best practice.

$ git clone git+ssh://git.debian.org/git/pkg-ime/fcitx.git

Then when Alioth meets something embarrassing, you can fork it at
Github and add remotes to your local copy, and the fork isn't
necessarily to be a newly forked one because we'll update it later
anyway.

$ cd fcitx
$ git remote add --mirror mirrored git://github.com/pkg-ime/fcitx.git
$ git remote add github git at github.com:<USERNAME>/fcitx.git
$ git pull mirror

... Make all sorts of changes and commit ...

$ git push github

... When Alioth is back ...

$ git push origin


You can also do such trick when you don't have a previously cloned
copy at hand. Here you need to have a fork of the pkg-ime repository
on Github. It doesn't matter whether the fork is newly created,
either.

$ git clone --origin github git at github.com:<USERNAME>/fcitx.git
$ git remote add origin git+ssh://git.debian.org/git/pkg-ime/fcitx.git
$ git remote add --mirror mirrored git://github.com/pkg-ime/fcitx.git
$ git pull mirrored

... Make all sorts of changes and commit ...

$ git push github

... When Alioth is back ...

$ git push origin




-- 
Regards,
Aron Xu



More information about the Pkg-ime-devel mailing list