Re: Rexecuting commands in an Emacs shell



On Tue, 15 May 2007 09:05:00 -0400, Dan Espen wrote:

General Schvantzkoph <schvantzkoph@xxxxxxxxx> writes:

On Mon, 14 May 2007 21:27:10 -0400, Dan Espen wrote:

General Schvantzkoph <schvantzkoph@xxxxxxxxx> writes:

On Mon, 14 May 2007 16:03:29 -0400, Dan Espen wrote:

General Schvantzkoph <schvantzkoph@xxxxxxxxx> writes:

On Mon, 14 May 2007 12:02:33 -0400, Dan Espen wrote:

General Schvantzkoph <schvantzkoph@xxxxxxxxx> writes:

What do I need to do to enable the ability to re-execute a
command in an Emacs shell? To clarify, when in an Emacs shell
it's always been possible to re-execute a command simply by
putting the cursor on that line in a buffer and doing a CR. I've
just built a copy of 21.4.20 on CentOS5 (which doesn't come with
an Xemacs RPM). In the Xemacs that I built command re-execution
doesn't work.

works here on 2.4.19.

Maybe you need to be more specific.

Yes I'm using M-x shell. It works on the versions of Xemacs that I
didn't build, i.e. FC6 and Cygwin, it's just the copies that I
built from source that have the problem.

To give you a very simple example, if I do an ls in the shell and
the re- execute the same line, i.e. put the cursor on the line that
has the ls on it, on the copies of Xemacs that were built by others
the ls will list the files again. On the copies of Xemacs that I
built myself, nothing happens.

So, you put the cursor in the line above, hit return and the cursor
doesn't move at all? Or does it move back to the prompt you started
on, or does it create a new prompt?

If you do:

^h k ret

in the shell buffer does it say:

RET runs `comint-send-input'

On the broken copies of Xemacs putting the cursor on a prior line and
the hitting return places the cursor at the end of the buffer and
otherwise does nothing. On the pre-built working copies placing the
cursor on a prior line cause that line to be replicated at the end of
the buffer and re-executed.

Here is the working case,

/home/bjrosen/foo> ls
bar
/home/bjrosen/foo> ls
bar
/home/bjrosen/foo>

Here is the broken case,

/home/bjrosen/foo> ls
bar
/home/bjrosen/foo>
/home/bjrosen/foo>

Ok, looks like it's not pulling the command down as it should.

You didn't do the "^h k RET" thing to check the mode map. Please do
that.

Also, try starting XEmacs with -q so it doesn't read your .emacs and
see if it works that way.

I know you keep associating this with compile from source but I don't
see the connection. Yet.
Most of the time I compile XEmacs from source too.

xemacs -q didn't make any difference.

^h k RET yields the same thing for both the working and non working
copies.

RET runs `comint-send-input'

`comint-send-input' is an interactive compiled Lisp function
-- loaded from "comint"
(comint-send-input &optional NO-NEWLINE ARTIFICIAL)


The NO-NEWLINE and ARTIFICIAL are not in the output I get. Looks like
your version is newer and operates differently.

Maybe someone else using a newer version has an idea.

In the version I have it proceeds to output a bunch of documentatation
about the function including the variables and functions used. You might
want to examine the variables and functions with ^h v and ^h f.

The variables all seem to have the same values for both the working and
non-working copies.
.



Relevant Pages

  • Re: Rexecuting commands in an Emacs shell
    ... when in an Emacs shell it's always ... Xemacs that I built command re-execution doesn't work. ... i.e. put the cursor on the line that has ... RET runs `comint-send-input' ...
    (comp.emacs.xemacs)
  • Re: Filemanager - low mem, but reasonably comfortable?
    ... >> Console is slow for me when it comes to typing in file names. ... And all the keybindings for copying names from the panels to the command ... Meta-Return copies whatever file or dir is under the cursor to the commandline. ... > Shell, or Gentoo file manager. ...
    (comp.os.linux.misc)
  • Re: Rexecuting commands in an Emacs shell
    ... when in an Emacs shell it's always ... Xemacs that I built command re-execution doesn't work. ... i.e. put the cursor on the line that has ... RET runs `comint-send-input' ...
    (comp.emacs.xemacs)
  • Re: Rexecuting commands in an Emacs shell
    ... when in an Emacs shell it's always been ... CentOS5 (which doesn't come with an Xemacs RPM). ... built command re-execution doesn't work. ... i.e. put the cursor on the line that has the ...
    (comp.emacs.xemacs)
  • Re: Rexecuting commands in an Emacs shell
    ... when in an Emacs shell it's always been ... CentOS5 (which doesn't come with an Xemacs RPM). ... built command re-execution doesn't work. ... i.e. put the cursor on the line that has the ...
    (comp.emacs.xemacs)