Le 12/03/2012 19:56, Vincent van Ravesteijn a écrit :
If you want a tree for both 2.0.x and 2.1.0svn, you can do the following:
Assume you have a git clone in <home>/lyx, you can clone this with
git clone -s -b 2.0.x <home>/lyx <home>/lyx20x
This will clone your repo, but it will reuse the objects. This means
that the second repo is much smaller than the first one.
OK, I have done that, and now I am trying to backport a patch to branch.
I don't want to be a git jedi just now, so I applied the patch I had to
my 2.0.x branch checkout, did 'git add' for the modified files,
a commit for good measure.
I am happy, I can do 'git format-patch' and see a nice formated patch
like the grown ups do.
Alas, now comes the time to put my patch to the git.lyx.org server. I do
a 'git push' in my 2.0.x branch to see what happens. Things happen
(cryptic messages I do not have anymore), but nothing in the lyx-cvs list.
OK, I think, the stuff has been committed from my shared 2.0.x directory
to the original lyx checkout on my computer, so I have to push there too.
But when I push in lyx/ (which is the full checkout), I get:
fantomas: git push
To g...@git.lyx.org:lyx
! [rejected] 2.0.x -> 2.0.x (non-fast-forward)
error: failed to push some refs to 'g...@git.lyx.org:lyx'
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes before pushing again. See the 'Note about
fast-forwards' section of 'git push --help' for details.
Where do I go from there? There has to be a simple way to commit a patch
to branch (please tell me there is!). I understand that plenty of
probably exciting and complicated ways of working on a branch have been
given, but I would like to start with trivial stuff like making a commit
of a bite-size patch on a branch.
JMarc