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

Update shell scripts #1265

Open
wants to merge 14 commits into
base: crashey
Choose a base branch
from
Open

Conversation

wiryhatbox
Copy link

  • Safer scripts with set -e and other options whenever possible

  • Make scripts more portable

  • Quote variables

  • Use end-of-options (--) to make scripts safer

  • Use either curl or wget with safer parameters

  • All commands (even mkdir/cd) exit properly on failure

  • x-prefix in comparisons no longer serves a purpose (shellcheck SC2268)

Change shell to sh

Quote variables
Exit with 1 on failure
Quote variables

More portable

Output all the missing commands instead of just the first

Use either curl or wget with safer parameters

Use end-of-options `--` whenever possible

All commands exit properly on failure

More readable
More portable

All commands exit properly on failure

Use either curl or wget with safer parameters

Make sure the user can run all commands

Quote variables

Use end-of-options `--` whenever possible
More portable

All commands exit properly on failure
Quote variables

More portable
Quote variables

All commands exit properly on failure
Do not send email by default

x-prefix in comparisons no longer serves a purpose
Make script safer with `set -euf`
More readable

Quote variables
@wiryhatbox
Copy link
Author

Let me know if you need help with the review.

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 this pull request may close these issues.

1 participant