Open
Conversation
Not all systems have Bash at this location. /bin/sh is required for POSIX-compliance however. Since (luckily) no Bashisms are used, there is no reason to require Bash’s extra weight.
…tting issues shellcheck recommended
Collaborator
|
Hi @toastal, many thanks for your contribution! In order for us to evaluate and accept your PR, we ask that you sign a contribution license agreement. It's all electronic and will take just minutes. |
Author
|
I may have signed the CLA? I am concern about privacy so I wish to not give my name or company so I left it blank (same as I don’t want to be on MS GitHub, but it’s unreasonable to delete this account until projects move on). If it is a concern, consider this trivial & committed under 0BSD. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Running on NixOS (& GuixOS-curious) I am acutely aware of scripts using
#!/bin/bashwhich isn’t on many systems.#!/bin/shis required for POSIX-compliance so can be relied on & the script is already POSIX-compliant for shell scripts (no Bashisms) so there is no reason to invoke a different shell; many script here are already pointing to#!/bin/sh.To check, I also ran
checkbashisms&shellcheckto make sure things were square. No Bashisms were used, butshellchecksuggested quoting all variables to be extra safe (separate commit). Additionally, there are some useless semicolons that can be dropped (separate commit). Feel free to cherrypick if/as needed.1
Footnotes
Please consider giving up MS GitHub or offering a non-proprietary, non-US-corporate-controlled mirror for this free software project. I wish to delete this Microsoft account in the future, but I need more projects like this to support alternative methods to send patches & contribute. ↩