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
goawk's printf family of functions under Windows #5
Comments
Hmm, that's strange. Does the AWK (or
So it surprises me that this would work on Windows. Does your first example work for awk and gawk too? From what I've seen by Googling, folks use double quotes but escape them according to Windows shell rules. |
It does not work with gawk 4.2.1.
The ^ symbol is the escape character for Windows cmd-prompt, but escaping the double-quote still results in a syntax error...
Even though single-quotes are not 'official', they still would be really nice to have under Windows. |
A source for a working version of mawk for Windows is located here: http://gnuwin32.sourceforge.net/packages/mawk.htm
|
I don't think I'm going to make this change, sorry. It's not per spec and I'd rather folks work around it on Windows using standard Windows escapes than change the syntax. |
I made a patch for this: https://gist.github.com/jftuga/840cc95139cd009621313ca30037e532 I copied the case statement for the double quotes in lexer.go and then changed the two instances of:
|
Thank you for making this change. I really appreciate it. |
Please let single-quotes be used in the printf family of functions. Example:
Under goawk:
Under Windows, the double-quote has to be used to combine space-containing arguments into one single, command-line argument. Single quotes can not be used. Therefore, single-quotes must be allowed in the goawk implementation of the printf family of functions. Can you please make it so that the printf family can use either single or double quotes?
The text was updated successfully, but these errors were encountered: