Skip to content
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

error in freight-cache script #138

Closed
sjoerdmullender opened this issue Oct 3, 2023 · 1 comment · Fixed by #139
Closed

error in freight-cache script #138

sjoerdmullender opened this issue Oct 3, 2023 · 1 comment · Fixed by #139

Comments

@sjoerdmullender
Copy link

I was looking at the differences between the current code and the code I am using and saw that one of the changes was the quoting of $FIND_L in the bin/freight-cache script.
Since FIND_L is set to either the empty string or the string -L, it should not be quoted in the call to find. If it is quoted (like now) and the value is the empty string (i.e. if $SYMLINKS is not on) you will get an error message from find (plus, admittedly, the desired output).

I saw this was changed in order to make shellcheck happy. I have no idea how it should be made happy, but this isn't it.

@RadxaYuntian
Copy link

The proper way to is to defined an Bash array to handle argument as described in shellcheck documentation though. If you use Bash array and it is empty, then Bash will not pass anything as argument.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants