axiom-developer
[Top][All Lists]
Advanced

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

Re: [Axiom-developer] A multi-line mode for Emacs.


From: Martin Rubey
Subject: Re: [Axiom-developer] A multi-line mode for Emacs.
Date: 19 Jun 2007 14:44:30 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4

Francois Maltey <address@hidden> writes:

> I'm looking at the AxiomEmacsMode.pamphlet and try to allow emacs to 
> send to axiom to multi-lines command in an *.input file.

great!

> I'll go to use the comint mode in order to improve the actual axiom.el mode.

Haeh? axiom.el already derives from comint mode.

> Are there others prompts in axiom ?
> 
>    ^(nn) -> 
> or Please enter y or yes if you really want to leave the interactive
>    environment and return to the operating system:
> or [...] Please confirm your request to have these listed by
>    typing y or yes and then pressing Enter :
> or BOOT>> 
> or BOOT>>>>

If you change to another lisp package, BOOT will change to be the name of this
package, as far as I know.

It would not surprise me at all if there were other prompts, too.

> How can I go out BOOT>> prompt ?

:qt


But really, the functionality you want to provide should be nearly independent
of axiom.el:

> Can Axiom evaluate every command in a *.input file after the 
> usual prompt (nn) -> ?

no, not at all. You have to put the command into a temporary input file, for
example "tmp.input" and then say

)re tmp.input

in the axiom buffer.  I think it would be OK to assume that the "*axiom*"
buffer is in the right state, i.e., that it has the "^(nn) ->" prompt.

Thus, I suggest you write a function

(defun axiom-send-input (str)
  (interactive)
  ...
)

that puts str into a temporary file tmp.input (best located in the /tmp
directory or the windows equivalent), then writes ")re /tmp/tmp.input" into the
"*axiom*" buffer and calls axiom-eval.

Martin





reply via email to

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