-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Esacape shell args to allow paths with spaces. #31
Conversation
@@ -1,5 +1,59 @@ | |||
#!/usr/bin/env bash | |||
|
|||
echo "-----------RUNNING MOCK LOUPER EXECUTABLE--------------" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bash script now verifies that the arguments passed in are valid
@@ -1,5 +1,66 @@ | |||
@echo off | |||
|
|||
echo "-----------RUNNING MOCK LOUPER.BAT EXECUTABLE--------------" | |||
echo Arguments passed to the script: %* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
batch script verifies arguments
:parse_args | ||
if "%~1" equ "" goto :check_paths | ||
|
||
if /i "%~1" equ "--input" ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The "%~1" will strip any surrounding quotes around the argument, but it seems to do wonky things depending on if there is a space between the equal sign.
--output="some path"vs
--output = "some apth"`
This should hopefully fix the issue on windows where output paths with spaces are causing bad inputs to the executable. It seems that using the
normalizePath
function on windows will convert relative paths to absolute paths, where on MacOS this isn't the case. This is why the issue of spaces in paths only has been reported by windows users.