[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: vc-git-log-incoming
From: |
Dan Nicolaescu |
Subject: |
Re: vc-git-log-incoming |
Date: |
Wed, 02 Jun 2010 05:23:07 -0400 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) |
Miles Bader <address@hidden> writes:
> vc-git-log-incoming seems to have a bunch of problems:
I was just typing a message asking what to do about some of these...
Input from more experienced git users would be appreciated.
> (1) By default, it uses "git log HEAD..XXX", where XXX is
> (vc-git-compute-remote), but this is only correct in some cases,
> because the current branch and the branch being pulled from don't
> necessarily have the same name (it failed on my emacs checkout, for
> instance).
>
> More correct would be to just use "address@hidden", which should
> use the actual upstream branch; however I think the "@{upstream}"
> feature was only added in git 1.7.0.
IMHO that would be fine too, we won't release emacs-24 anytime soon.
>
> (2) If the user doesn't use the default, it just does "git log YYY",
> where YYY is what the user entered, but this is probably not what's
> wanted; really it should use "HEAD..YYY".
That should not be too hard to do.
> (3) Most seriously, just using git-log like this doesn't actually give
> a list of what will be pulled, because "git pull" first updates the
> local copy of the remote's branches, whereas "git log" does not.
>
> I'm not totally sure how to do this correctly -- you can get the
> range of revisions that would be added during pulling (by the
> underlying call to "git fetch") by using "git fetch --dry-run", but
> that's not going to give you a log output....
This is the main problem... maybe vc-git-log-incoming can look for an
empty "git log" output, and offer to run "git fetch", and then rerun log...