bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#57807: 29.0.50; Make vc-print-branch-log able to log multiple branch


From: Juri Linkov
Subject: bug#57807: 29.0.50; Make vc-print-branch-log able to log multiple branches
Date: Fri, 16 Sep 2022 09:59:09 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu)

>>>>>> Is this equivalent to `M-& git log origin/scratch/posix-spawn 
>>>>>> 4b2ca6bfc0`,
>>>>>> then enabling vc-git-log-view-mode in the output buffer?
>>>>>
>>>>> It's not, because vc-git-log-view-mode requires you pass four or five
>>>>> options to git-log to get output it can properly display.  That
>>>>> knowledge is locked up in vc-git.el right now.
>>>>
>>>> This part is clear, but I also wanted to know what git command
>>>> corresponds to this feature.  Is it just `git log` with two
>>>> branch names on the command line?  What additional options
>>>> are required?  Maybe `--graph --oneline`?  Also I see that
>>>> git documentation mentions `--branches[=<pattern>]`.
>>>
>>> It's something along these lines:
>>>
>>> git log -100 --graph --decorate --date=short \
>>>     --pretty="tformat:%d%h..: %an %ad %s" --abbrev-commit \
>>>     BRANCH1 BRANCH2
>>
>> This is what I proposed a long ago, maybe it makes sense here.
>> After invoking a vc command with a prefix argument it could pop up
>> the minibuffer with the command line that you can edit to add or delete
>> more arguments for the git command.  So e.g. after 'C-u C-x v b l BRANCH1 
>> RET'
>> it will insert in the minibuffer the default command `git log ... BRANCH1`,
>> where you can add BRANCH2 and modify any other option.  Then it runs
>> this command and displays the output in the vc-git-log-view-mode buffer.
>
> That would be enough for me.  vc-push already works that way.  Shall I
> look into preparing a patch?

Yes, please try to prepare a patch, preferably without changing the
established backend API, maybe by using a global variable that later
could be reused to confirm and edit other commands.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]