-
Notifications
You must be signed in to change notification settings - Fork 34
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
Feature: Helper to convert expressions to shell command strings #79
Comments
That sounds like it could be useful, and it might be a nice improvement over our current debug printing also. I wonder how we would want to represent some of these more complicated features in a cross-platform way:
|
Interesting. I could go either way on displaying all the extra complexity, and I won't pretend to know how cross-platform this is, but for unix:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I was creating complex expressions using duct and found myself wanting ways to easily print out the shell command in a way that I could easily copy-paste debug in a bash (or similar) shell to debug, to be able to do something like:
I started with some custom simple escaping that seemed good enough for my use case, but I found shell_escape to be more a bit more complete and ended up with something like this:
Which allowed me to print out abnormally complex expressions like:
I could also imagine extending this to prefix environment variables to the shell string (e.g.
foo=bar mycmd arg1 'another arg'
). Just an idea; feel free to close if this doesn't fit into the scope of duct.The text was updated successfully, but these errors were encountered: