Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
make-disk-image.nix: Really fix write permissions in the store
I think the current one applies the -exec only to those that match '-type d'. Let's switch it to something that humans can understand... (cherry picked from commit 758b4c1) (Yes it should use 'find -print0 | xargs -0' but I'm really afraid of screwing up again in the same way. Nix doesn't allow spaces and/or newlines in store paths anyway and it has -maxdepth 1 -mindepth 1 so it won't fail in practice. If someone can provide a *tested* that doesn't suffer from the same problems, feel free to improve.)
- Loading branch information
a7664a6
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.
I don't understand how this differs!
a7664a6
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.
I don't understand either.
a7664a6
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.
a7664a6
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.
So the
exec
is somehow treated as part of the predicate?? Ugh 😄a7664a6
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.
Yeah. I suppose it's a "feature" so that one can do uber complex things like
find -type f -exec command-if-file '{}' \; -o -type d -exec command-if-directory '{}' \;
all in a singlefind
command...a7664a6
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.
Makes sense I guess 😄