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

Automatic quotation of interpolations #37

Open
yevhen opened this issue Apr 26, 2020 · 0 comments
Open

Automatic quotation of interpolations #37

yevhen opened this issue Apr 26, 2020 · 0 comments

Comments

@yevhen
Copy link
Owner

yevhen commented Apr 26, 2020

Since the actual values that will be inlined from interpolations are opaque, to get rid of possible misinterpretation of values that may contain spaces, the interpolations need to be quoted, e.g. await $"app '{path}'".

It would be super-cool if we can do the automatic quotation of interpolated expressions when such strings are the input to await or Shell.Run.

Concerns:

  • Interpolations which area already quoted
  • Interpolations which reside inside quotes, e.g. await $"app 'some {path} arg with spaces'"
  • Interpolations which reside between quotes, e.g. await $"app 'arg1' {path} 'arg2'"
  • How to determine if interpolation should be quoted for a particular invocation (e.g. call to Shell.Run)?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant