Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 312773 - dev-vcs/mercurial-1.5: hgeditor does not close the diff window when :wq'ing the commit message window (patch included)
Summary: dev-vcs/mercurial-1.5: hgeditor does not close the diff window when :wq'ing t...
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Dirkjan Ochtman (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-02 10:36 UTC by Itamar Ravid
Modified: 2010-04-02 17:19 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
patch to make hgeditor behave nicely (hgeditor_treat_diff_window_as_help.patch,458 bytes, patch)
2010-04-02 10:37 UTC, Itamar Ravid
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Itamar Ravid 2010-04-02 10:36:08 UTC
Hey guys, I started using hgeditor for editing commit messages so I can see the diff when commiting. Problem is, I have to :wq twice now. This is rather annoying, so I shamelessly stole these arguments from the Mercurial wiki. Would be rather nice to see these integrated as a patch to the ebuild, so I'll attach a patch. :)

Reproducible: Always
Comment 1 Itamar Ravid 2010-04-02 10:37:00 UTC
Created attachment 226257 [details, diff]
patch to make hgeditor behave nicely
Comment 2 Andreas K. Hüttel archtester gentoo-dev 2010-04-02 13:38:10 UTC
What if someone sets $EDITOR to something else? 
Or is this fixed to some particular value in the program?
Comment 3 Itamar Ravid 2010-04-02 17:04:30 UTC
(In reply to comment #2)
> What if someone sets $EDITOR to something else? 
> Or is this fixed to some particular value in the program?
> 

Well, upstream states that you must customize hgeditor yourself if you wish to support editors other than emacs/vi. 

Admittedly, the patch I submitted would not work for emacs. I could modify it to only apply the arguments in case $EDITOR is gvim/vim; there's a case statement in the hgeditor script that tests for $EDITOR values.
Comment 4 Dirkjan Ochtman (RETIRED) gentoo-dev 2010-04-02 17:19:00 UTC
Please fix the patch up so that it doesn't cause problems for emacs users, then take this upstream. It sounds like it makes sense, but I don't know myself, and since hgeditor comes from upstream and this doesn't sound like a very bad bug that we need a patch for, I'd prefer to let our upstream team handle this.