|
From: | Rik |
Subject: | Re: File separator on MinGW |
Date: | Wed, 27 Nov 2013 13:56:08 -0800 |
On 11/27/2013 01:26 PM, John W. Eaton wrote: > On 11/27/2013 02:54 PM, Rik wrote: >> 11/27/13 >> >> When I type 'ls bi<Tab>' in a directory that has a subdirectory "bin" the >> parser auto-completes to "bin/". Shouldn't it be using the value of >> filesep() as the final character in the auto-complete? Where is that code >> kept? > > I'm pretty sure it's readline that's doing that. There are several hook functions for dealing with directory name completion. But since Windows accepts either / or \ as the directory separator, I don't see this as an urgent problem. > > jwe > It's not urgent, but just because Windows accepts either separator doesn't mean that Octave does as well. I came across this because of three instances, although there are more if you grep for filesep comparisons in the scripts directory. "ls bin/" fails with Invalid switch - "". error: ls: command exited abnormally with status 127 because ls_command() on Windows is dir /D and runtests dir_name/ also fails because it is looking for either a bare directory name or a name with the appended filesep. Finally, what bin/ error: what: subscript indices must be either positive integers less than 2^31 or logicals error: called from: error: C:\Documents and Settings\Rik\My Documents\Octave\octave-2013-11-27-09-34\share\octave\3.7. 7+\m\miscellaneous\what.m at line 36, column 7 All examples work if the correct Windows file separator is used. --Rik |
[Prev in Thread] | Current Thread | [Next in Thread] |