octave-maintainers
[Top][All Lists]
Advanced

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

Re: retaining interpreter when running script from command line


From: John W. Eaton
Subject: Re: retaining interpreter when running script from command line
Date: Thu, 3 Mar 2005 21:40:45 -0500

[moved from the help list --jwe]

On  3-Mar-2005, Andy Adler <address@hidden> wrote:

| We may not need --funcall, but I propose we leave it there,
| since it may be useful, and isn't in the way or anything.

In a way it is, because then we have to decide what to do when both
options are supplied, and it complicates the implementation to have
two ways of doing essentially the same thing.

How about the attached changes?  With them, you do things like

  octave --eval CODE                   # eval CODE, exit
  octave --persist --eval CODE         # eval CODE, go interactive
  octave doit.m                        # eval file, exit
  octave --persist doit.m              # eval file, go interactive
  octave --eval CODE doit.m            # eval CODE, file, exit
  octave --persist --eval CODE doit.m  # eval CODE, file, go interactive

I don't see a need for --funcall now because

  --funcall function_name

is essentially the same as

  --eval function_name

and I don't see a good reason to have both.

Finally, should we also warn about using more than one --eval option?
Currently, only the last one will be evaluated and no warning will be
issued.

jwe

Attachment: diffs.gz
Description: Binary data


reply via email to

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