I have one more question: In the branch creation explanation: This makes a local branch. If you want to mirror this local branch on the archer server (which we encourage -- it is better to share), push it: $ git push origin archer-tromey-explosion-project:archer-tromey-explosion-project Note that this command is only useful the first time you push your branch to the repository. For subsequent pushes, you should omit master: $ git push origin archer-tromey-explosion-project What does omit master mean here? There is no master in the first "git push" Pierre Muller GDB pascal language maintainer
> This makes a local branch. If you want to mirror this local branch on
> the archer server (which we encourage -- it is better to share), push it:
>
> $ git push origin
> archer-tromey-explosion-project:archer-tromey-explosion-project
>
> Note that this command is only useful the first time you push your branch to
>
> the repository. For subsequent pushes, you should omit master:
>
> $ git push origin archer-tromey-explosion-project
Hmmm, I thought that
$ git push origin archer-tromey-explosion-project
would have worked right from the get go...
--
Joel
On Thu, 24 Feb 2011 12:32:28 +0100, Joel Brobecker wrote:
> Hmmm, I thought that
>
> $ git push origin archer-tromey-explosion-project
>
> would have worked right from the get go...
Really not:
$ rm -rf 1 2;mkdir 1 2;cd 1;git init;touch f;git add f;git commit -m f f;cd ..;git clone 1 2;cd 2;git checkout -b x;git push origin ;cd ../1;git branch;cd ..
Switched to a new branch 'x'
Everything up-to-date
* master
but
$ rm -rf 1 2;mkdir 1 2;cd 1;git init;touch f;git add f;git commit -m f f;cd ..;git clone 1 2;cd 2;git checkout -b x;git push origin x:x;cd ../1;git branch;cd ..
Switched to a new branch 'x'
Total 0 (delta 0), reused 0 (delta 0)
To /tmp/gittest3/1
* [new branch] x -> x
* master
x
Regards,
Jan
On Thu, 24 Feb 2011 12:26:01 +0100, Pierre Muller wrote:
> $ git push origin
> archer-tromey-explosion-project:archer-tromey-explosion-project
>
> Note that this command is only useful the first time you push your branch to
>
> the repository. For subsequent pushes, you should omit master:
>
> $ git push origin archer-tromey-explosion-project
>
> What does omit master mean here?
> There is no master in the first "git push"
One can call probably `master' either `archer-tromey-explosion-project' on the
left or `archer-tromey-explosion-project' on the right - it is important there
should no longer be any colon (':'). Anyway the examples work as intended so
I am not sure how they should be commented.
Regards,
Jan
> > Hmmm, I thought that > > > > $ git push origin archer-tromey-explosion-project > > > > would have worked right from the get go... > > Really not: (I don't know if I'm the only one feeling that way, but your style is insanely compact for my brain - it often takes a long time to understand what you're trying to say sometimes) > $ rm -rf 1 2;mkdir 1 2;cd 1;git init;touch f;git add f;git commit -m f f;cd ..;git clone 1 2;cd 2;git checkout -b x;git push origin ;cd ../1;git branch;cd .. > Switched to a new branch 'x' > Everything up-to-date > * master > but > $ rm -rf 1 2;mkdir 1 2;cd 1;git init;touch f;git add f;git commit -m f f;cd ..;git clone 1 2;cd 2;git checkout -b x;git push origin x:x;cd ../1;git branch;cd .. > Switched to a new branch 'x' > Total 0 (delta 0), reused 0 (delta 0) > To /tmp/gittest3/1 > * [new branch] x -> x > * master > x I think I didn't express myself clearly. All I was trying to say is that "x:x" in a "git push" command is equivalent to "x". I wasn't understanding the reasoning behind the instructions, but maybe I was missing something, or making the wrong assumption somewhere (I was assuming that Pierre named both local and remote branches with the same name). -- Joel
On Sun, 27 Feb 2011 19:17:52 +0100, Joel Brobecker wrote: > > Really not: > > (I don't know if I'm the only one feeling that way, but your style > is insanely compact for my brain - it often takes a long time to > understand what you're trying to say sometimes) Thanks for the feedback, still in this case I believe the problem was different: > > $ rm -rf 1 2;mkdir 1 2;cd 1;git init;touch f;git add f;git commit -m f f;cd ..;git clone 1 2;cd 2;git checkout -b x;git push origin ;cd ../1;git branch;cd .. + > > $ rm -rf 1 2;mkdir 1 2;cd 1;git init;touch f;git add f;git commit -m f f;cd ..;git clone 1 2;cd 2;git checkout -b x;git push origin x:x;cd ../1;git branch;cd .. > I think I didn't express myself clearly. This is completely a mistake on my side. I tested something different than what you said. $ rm -rf 1 2;mkdir 1 2;cd 1;git init;touch f;git add f;git commit -m f f;cd ..;git clone 1 2;cd 2;git checkout -b x;git push origin x ;cd ../1;git branch;cd .. Switched to a new branch 'x' Total 0 (delta 0), reused 0 (delta 0) To /tmp/gittest3/1 * [new branch] x -> x * master x It really works the way you say. I have updated the Wiki now: http://sourceware.org/gdb/wiki/ArcherBranchManagement?action=diff&rev2=121&rev1=120 > All I was trying to say is > that "x:x" in a "git push" command is equivalent to "x". Yes, it is. I did not know it myself. Thanks, Jan