-
Notifications
You must be signed in to change notification settings - Fork 43
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
fix: quoting of PRJ_PATH/fragment for installables #358
Conversation
I also enabled showing the actual command with The precommit hooks in the devshell also put the updated flake.locks into this commit. Not sure about that. |
I see the string created here https://github.com/paisano-nix/core/blob/3e897a19418361ece34841105122ed4f9379ca96/grow/newExtractFor.nix#L10 |
@whs-dot-hk I am not quite sure what you are getting it. Maybe somemore context on what I did with the fragment: I am quoting the fragment for shell usage. That would actually mean that the string including the double quotes is passed to the nix command. Right now they are interpreted by bash, so that the string passed to the command does not contain the quotes anymore. That would make a difference, if anything in the path would contain spaces or other special characters, otherwise not so much. Still, I think it is generally good practice to quote things properly so that you don't even have to think about corner cases. |
I was trying to understand what is fragment, it seems that it means a flake fragment I am not sure where to escape, but I think yours is a good place Do other places in the code also need to change? |
Hard to say.
Otherwise one would need to go through all instances in which nix variables are injected into shell scripts (that are not just store paths) and escape them. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That looks pretty sensible, indeed!
Let's wait for the test run.
The flake lock update is an ugly attempt for sub- / superflake compliance untill subflakes get better upstream support.
#357