help-octave
[Top][All Lists]
Advanced

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

Re: Home directory in octave on windows?


From: Michael Goffioul
Subject: Re: Home directory in octave on windows?
Date: Wed, 3 Jun 2009 08:53:03 +0100

Under Windows, the home directory is computed using
2 methods:

1) HOME variable
2) HOMEDRIVE and HOMEPATH variables

The first method takes precedence.

Michael.


On Wed, Jun 3, 2009 at 8:07 AM, Tatsuro MATSUOKA <address@hidden> wrote:
> Hello
>
> HMMMMMMM ????
>
> In my case,
>
> I added
>
> putenv('HOME','D:\usr')
>
> in the last line of
> C:\Programs\Octave\3.0.5_gcc-4.3.0\share\octave\3.0.5\m\startup\octaverc
>
> and start octave
>
>> tilde_expand ('~')
> ans = D:\usr
>
> Then I changed the last line to
>
> putenv('HOME','D:\usr\tatsu')
>
> and quited octave and restarted octave
>
>> tilde_expand ('~')
> ans = D:\usr\tatsu
>
> As written the above, in my case putenv('HOME',(folder path)) worked well to 
> change '~'..
>
> This is what I did when I wrote the previous post.
>
> Note My os is windows xp pro sp3 and I log on as an administrator.
>
> Regards
>
> Tatsuro
>
>
>
> --- m h  wrote:
>
>> Tatsuro, thanks for the suggestions.
>>
>> Here is what I tried:
>> I disconnected the U: drive, to see what would happen. Then I started the 
>> octave.exe file (the
>> normal way, double clicking on the file in Windows explorer). After startup, 
>> here's what
>> happens:
>>
>> -----------------------------------
>>
>> > tilde_expand("~")
>> ans = U:\
>> octave.exe:2:C:\Program Files (x86)\Octave\3.0.5_gcc-4.3.0\bin
>> > getenv("HOME")
>> ans =
>> octave.exe:3:C:\Program Files (x86)\Octave\3.0.5_gcc-4.3.0\bin
>> > ls ~
>> The system cannot find the path specified.
>> error: ls: command exited abnormally with status 127
>> error: evaluating if command near line 59, column 7
>> error: evaluating if command near line 55, column 5
>> error: evaluating if command near line 49, column 3
>> error: called from `ls' in file `C:\Program Files 
>> (x86)\Octave\3.0.5_gcc-4.3.0\s
>> hare\octave\3.0.5\m\miscellaneous\ls.m'
>> octave.exe:3:C:\Program Files (x86)\Octave\3.0.5_gcc-4.3.0\bin
>> >
>>
>> -----------------------------------
>>
>> The last command happened because U:\ no longer exists (I disconnected the 
>> network drive).
>> So ~ and HOME seem to be two different things. And Octave insists on 
>> creating (if it doesn't
>> already exist) a new .octaverc in the ~ directory , not the HOME directory.
>>
>> Any idea what's going on? How does Octave determine what the ~ directory is 
>> in Windows? It's
>> apparently not the HOME directory.
>>
>> Thanks,
>>
>> --- Marc
>>
>>
>>
>> ________________________________
>> From: Tatsuro MATSUOKA <address@hidden>
>> To: address@hidden; m h <address@hidden>; address@hidden
>> Sent: Thursday, May 28, 2009 6:44:04 PM
>> Subject: Re: Home directory in octave on windows?
>>
>> Hello
>>
>> I have remembered the other way
>>
>> Please write the below
>>
>> putenv('HOME','D:\usr')
>>
>> (octave-home) /share/octave/site/m/startup/octaverc or
>> (octave-home) /share/octave/version/m/startup/octaverc
>>
>> Perhaps this way is smart than that I have show in previous post.
>>
>> Regards
>>
>> Tatsuro
>>
>> --- Tatsuro MATSUOKA < wrote:
>>
>> > Hello
>> >
>> > I have mislead.
>> >
>> > Please set environment variable 'HOME' in the windows.
>> >
>> > In my case HOME is set to 'D:\usr\tatsu'
>> > > ls ~
>> >  Volume in drive D has no label.
>> >  Volume Serial Number is ACCF-78A8
>> >
>> >  Directory of D:\usr\Tatsu
>> >
>> >
>> > For the way to set environment variables, please see:
>> > http://lifehacker.com/259018/
>> > Create your own environment variables for quick folder navigation
>> >
>> > Regards
>> >
>> > Tatsuro
>> >
>> > --- m h wrote:
>> >
>> > > I'm running Octave-3.0.5 on a WinVista machine.
>> > >
>> > > Right now, it seems that octave insists that my home directory
>> > > (whatever that means on windows), i.e. the directory that is listed when
>> > > I type "ls ~", is a network drive that my computer is connected to,
>> > > specifically a drive that's mounted as U: . This also unfortunately 
>> > > means my
>> > > .octaverc file, log file, etc, get created and written to the root 
>> > > directory of U:
>> > > . I'd like that to be somewhere else.
>> > >
>> > > How do I change where octave thinks the home directory is? Can I tell
>> > > it to look for a .octaverc file (and store log files) somewhere else?
>> > > Or is that hard coded into the executable that I download?
>> > >
>> > > Thanks...
>> > >
>> > > --- Marc
>> > >
>> > >
>> > >
>> > >       > _______________________________________________
>> > > Help-octave mailing list
>> > > address@hidden
>> > > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave
>> > >
>> >
>> >
>> > --------------------------------------
>> > Power up the Internet with Yahoo! Toolbar.
>> > http://pr.mail.yahoo.co.jp/toolbar/
>> > _______________________________________________
>> > Help-octave mailing list
>> > address@hidden
>> > https://www-old.cae.wisc.edu/mailman/listinfo/help-octave
>> >
>>
>>
>> --------------------------------------
>> Power up the Internet with Yahoo! Toolbar.
>> http://pr.mail.yahoo.co.jp/toolbar/
>>
>>
>>
>>
>
>
> --------------------------------------
> Power up the Internet with Yahoo! Toolbar.
> http://pr.mail.yahoo.co.jp/toolbar/
> _______________________________________________
> Help-octave mailing list
> address@hidden
> https://www-old.cae.wisc.edu/mailman/listinfo/help-octave
>



reply via email to

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