[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: CLI hook on leave
From: |
Ben Abbott |
Subject: |
Re: CLI hook on leave |
Date: |
Wed, 06 Nov 2013 13:37:16 -0500 |
On Nov 6, 2013, at 12:37 PM, Arve Gengelbach wrote:
> Hi all,
>
> On the command line:
> I would want to run ‘close all’ every time I leave octave’s interactive mode
> (pressing Ctrl+D or with exit).
> Is there some possibility to run code before exiting the interactive CLI?
>
> cheers
> Arve
I haven't tried it myself, but if you place the line below in your ~/.octaverc,
then Octave should "close all" as it exists.
atexit ("close", "all")
Ben