Skip to content

Remove custom escaping for external args.#2095

Merged
sophiajt merged 1 commit intonushell:masterfrom
thegedge:fix-bad-shell-escaping
Jul 2, 2020
Merged

Remove custom escaping for external args.#2095
sophiajt merged 1 commit intonushell:masterfrom
thegedge:fix-bad-shell-escaping

Conversation

@thegedge
Copy link
Copy Markdown
Contributor

@thegedge thegedge commented Jul 2, 2020

Our own custom escaping unfortunately is far too simple to cover all cases. Instead, the parser will now do no transforms on the args passed to an external command, letting the process spawning library deal entirely with escaping.

Closes #1957

Still works for these two:

One case that doesn't work, but would likely require us to build custom parsing for external strings:

$ ^echo test' "ing"'
test' ing'

For that one I would have expected the output to be test "ing"

Our own custom escaping unfortunately is far too simple to cover all cases.
Instead, the parser will now do no transforms on the args passed to an external
command, letting the process spawning library deal with doing the appropriate
escaping.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Quotes in external command string parameter being escaped when they shouldn't be

3 participants