paulo-fernando-silva / vscOctaveDebugger

MIT License
35 stars 4 forks source link

addpath on workingDirectory results in Invalid Path #60

Closed tmayer18 closed 2 years ago

tmayer18 commented 2 years ago

When running the debugger, I receive a warning produced by the addpath that sets up the required path directories:

warning: addpath: c:\Users\...\Code\Homework:C:\Users\...\Code\MATLAB Scripts: No such file or directory

(note that ... has replaced long intermediate filepaths with identifying information)

The issue here is that the two paths are being separated by the : character rather than the pathsep() value. My octave installation returns ; when running pathsep(), which I suspect to be due to me running on a Windows OS. If I manually run addpath with the same string, but with the ; between the two paths, it works as it should, though I would prefer to not explicitly run addpath at the start of all my scripts.

I took at look at the source, but I don't know Typescript or VSC extensions at all, and couldn't see where this character was being added. The comment on this line however claims to separate explicitly with the :, so I will believe that. https://github.com/paulo-fernando-silva/vscOctaveDebugger/blob/70a03e07a8f228cd9cb7b9f524f8f46d22c39679/src/Commands.ts#L26

If there is a configuration fix that I have overlooked that would address this problem, please let me know.

paulo-fernando-silva commented 2 years ago

Thanks for pointing that out. Version v0.4.24 should fix that. Please reopen the bug if it doesn't work for you.