[Gretl-devel] set workdir

Allin Cottrell cottrell at wfu.edu
Thu Jan 10 20:59:08 EST 2008


I was asked earlier: now that the gretl working directory is 
configurable via the GUI, is/should there be a script means of 
setting it?

On the general principle that anything you can do via the GUI, you 
ought to be able to do via the command line if at all possible, 
the answer is "yes" to the "should" branch of the question, and 
now in CVS it's also "yes" to the "is" branch.

However, I'm treating this as a somewhat special "set" variable.
Most such variables are settable within user-defined functions, 
but the settings are internal to the function: when the function 
exits, the settings revert to what they were at the caller level.

The working directory, though, seems to me a slightly different 
thing.  I can't see any compelling reason for messing with this 
inside functions.  So it's configured as settable only at the "top 
level" of command execution (console or script).  

set workdir /some/path/that/exists

( or, if you must,

set workdir "c:\Some Path\That exists with holes" )

should work now, but not inside a function.

Allin.


More information about the Gretl-devel mailing list