-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Can't seem to pass a string contains a "#" to a nushell script #6957
Comments
Try
Emm , final out put then will be
use signal quotation marks, because the args have quotation marks, then in nushell, it is turned to string, then the string received by nushell will from "ss#" -> ss#, Maybe there will be a good solution for such kind of thing |
I have similar problem but with "a(b)c" it says executable was not found echolino.nu #!/nushell-0.70.0/bin/nu --stdin
def main [ p: string ] {
echo $p
} than from bash
It list my files, Curously if I add an space doesnt work
|
To address this issue, please use string literal, something like " \' xxxxxx \' ", quotes do not work because std::env::args() does not reserve the quotes, the input |
Did this get fixed?
I see the same behavior if I single/double quote it. |
(to be clear, it appears fixed to me, but the PR didn't mention this issue. I'll leave this for a bit in case I'm confused, but I think this can probably be closed! Exciting!!) |
And one last note, it also works passing it to a nushell script, which I think was part of my problem:
|
Thanks for checking back in on this issue @colemickens! I think you are correct that this was fixed (different PR to #7398) Fixed in #8151 |
Describe the bug
I can't seem to pass a string containing a pound sign ("#") to a nushell script:
cat minimal.nu
I did try searching for other open issues, however, this one is hard to discover. I even know of #6741 but couldn't find it organically when searching Issues.
This seems more unexpected/bug-like than #6741 so I wanted to go ahead and open it.
How to reproduce
Try to pass a string containing a '#' to a nushell script, find that it is very difficult, or maybe impossible to do so without it being truncated.
Expected behavior
Some sort of workaround/quoting behavior, etc.
Screenshots
No response
Configuration
nu --version
says 0.70.0 but I get it from the flakeAdditional context
No response
The text was updated successfully, but these errors were encountered: