Re: How to figure out what 'git push' would do?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Steffen Prohaska, Sun, Aug 05, 2007 21:56:37 +0200:
> >
> >    $ git fetch
> >    $ gitk local..REPO/master
> >
> 
> That applies only for a single branch. If I prepared a couple of
> branches for pushing and somehow want to double check what I prepared,
> 'git push --dry-run' would be quite handy. I know how to handle the
> situation and could write a custom script that does all necessary
> checks. But I haven't found an out-of-the-box solution for double
> checking right before 'git push'

Well, you can do gitk local1..REPO/remote1 local2..REPO/remote2,
of course, but yes, there is not out-of-the-box solution.

And a straight-forward implementation of "git-push --dry-run" doesn't
look simple... The remote sides git-receive-pack still have to be
called for any useful information, like the references updated and the
SHA-1s they get. IOW, if you can update your system easily to support
--dry-run, it still does not mean the server admin will do that just
as readily. And AFAICS, receive-pack dies if given a parameter it
does not know (it dies on every command line argument which begins
with "-", as it looks). Maybe we should change that first for a very
slow start...

It is simplier to modify git-ls-remote of git-remote to just compare
reference on local and remote side.

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux