Skip to content
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

Quote command line arguments if necessary when printing them #6334

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kit-ty-kate
Copy link
Member

opam sometimes prints out command lines that it execute. However the printing function does not print the command line correctly. In particular if a space is included it cannot be recognized from other similar commands.
For example echo a b and echo 'a b' would be printed the same even though they are different commands.

This draft PR quotes arguments/commands if any special characters is encountered.
The syntax chosen is the sh/bash syntax on Unix and the cmd/powershell syntax on Windows.

Related to #5492

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant