<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>19736</bug_id>
          
          <creation_ts>2009-04-23 18:09:18 +0400</creation_ts>
          <short_desc>eshell should set EDITOR (at least, when needed)</short_desc>
          <delta_ts>2009-04-23 23:11:35 +0400</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>3</classification_id>
          <classification>Distributions</classification>
          <product>Branch 4.1</product>
          <component>emacs22-common</component>
          <version>unspecified</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>NOTABUG</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P3</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ivan Zakharyaschev">imz</reporter>
          <assigned_to name="Eugene Vlasov">eugvv</assigned_to>
          
          
          <qa_contact name="qa-4.1@altlinux.org">qa-4.1</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>89974</commentid>
    <comment_count>0</comment_count>
    <who name="Ivan Zakharyaschev">imz</who>
    <bug_when>2009-04-23 18:09:18 +0400</bug_when>
    <thetext>emacs22-common-22.2-alt5

It would be convenient if eshell set EDITOR=emacsclient (at least if EDITOR is initially unset, or perhaps better always).

Then, in the following case, the message could be edited in an Emacs buffer, when &quot;git commit&quot; is called in eshell: 

~/.ssh $ git commit
Terminal is dumb but no VISUAL nor EDITOR defined.
Please supply the message using either -m or -F option.
~/.ssh $</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>89997</commentid>
    <comment_count>1</comment_count>
    <who name="Eugene Vlasov">eugvv</who>
    <bug_when>2009-04-23 23:11:35 +0400</bug_when>
    <thetext>There is several ways to do that:

1. Set EDITOR variable in your session (or just run emacs as &quot;EDITOR=emacsclient emacs&quot;).
2. Use something like

(add-hook &apos;eshell-mode-hook
         &apos;(lambda () (setenv &quot;EDITOR&quot; &quot;emacsclient&quot;)))

in your init-file
3. Or use M-x shell (M-x term) (and set this variable in ~/.emacs_SHELLNAME).</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>