help-octave
[Top][All Lists]
Advanced

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

Re: how to change the path in the console


From: Nicholas Jankowski
Subject: Re: how to change the path in the console
Date: Sat, 22 Jun 2013 12:48:24 -0400

information about the startup files can be found here:
http://www.gnu.org/software/octave/doc/interpreter/Startup-Files.html

The file Ben pointed out contains your local preferences. A few versions ago, the default starting location was changed so that Octave will always start in your home folder (on Windows, this would be C:\Documents and Settings\james\).  I found it more convenient to have the program start in the same location as the shortcut I made for Octave, and I would just copy an Octave shortcut to the base folder of each project I was working on.

the command for Octave to default to your home folder is in the global settings file, located at
octave-home/share/octave/site/m/startup/octaverc
you'll see the last line
cd(getenv('USERPROFILE'))

I always comment this line out (put a ## in front of it). Then I open the properties on the Octave shortcut and blank the 'start in' location. This causes the program to start wherever the shortcut is located. then as I said, I drop an Octave shortcut at the root of any project folder i'm working in. maybe a bit cumbersome, but it works for me.

nickj


On Fri, Jun 21, 2013 at 9:29 PM, Ben Abbott <address@hidden> wrote:
On Jun 22, 2013, at 4:30 AM, dbonneau wrote:

> My path is C:\Documents and Settings\james\My
> Documents\school\test\gd\hw1\ex, and I saved it using addpath(c:\xxxxxxxxx).
> How do I change the path in console so I don't have to type above path every
> time I opned up Octave.
>
> Thanks

You can add a cd (...) command to your ~/.octaverc file

        cd ("C:\Documents and Settings\james\My Documents\school\test\gd\hw1\ex")

Ben

_______________________________________________
Help-octave mailing list
address@hidden
https://mailman.cae.wisc.edu/listinfo/help-octave


reply via email to

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