-
Notifications
You must be signed in to change notification settings - Fork 522
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
windows_utils.bzl: Escaping \ and " before passing args to bash scrip… #1685
Conversation
I guess I need to add a test for this. |
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.
Awesome thank you for the fix!!
* limitations under the License. | ||
*/ | ||
|
||
const process = require('process') |
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.
nit: the process
global variable is defined in a nodejs context without needing a require statement
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.
Done
@@ -96,7 +96,12 @@ set RUNFILES_MANIFEST_ONLY=1 | |||
call :rlocation "{sh_script}" run_script | |||
for %%a in ("{bash_bin}") do set "bash_bin_dir=%%~dpa" | |||
set PATH=%bash_bin_dir%;%PATH% | |||
"{bash_bin}" -c "!run_script! %*" | |||
set args=%* |
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.
would be nice to have some comments here to explain that this is escaping the arguments
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.
Cool, comments added.
…t with quote
PR Checklist
Please check if your PR fulfills the following requirements:
PR Type
What kind of change does this PR introduce?
What is the current behavior?
#1671
What is the new behavior?
On Windows, passing command line args to node_binary is more consistent with Linux.
Does this PR introduce a breaking change?
Other information