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

Why bash? wouldn't sh be enough? #67

Closed
jaromil opened this issue Mar 28, 2023 · 4 comments
Closed

Why bash? wouldn't sh be enough? #67

jaromil opened this issue Mar 28, 2023 · 4 comments

Comments

@jaromil
Copy link

jaromil commented Mar 28, 2023

The script is still small enough to migrate to /bin/sh without much effort, leading to a more portable script. I would suggest you do so.

@0xacx
Copy link
Owner

0xacx commented Mar 29, 2023

What would the advantages be in practice?
I mean, what modern system does not support bash but supports sh?
The only case I could think of is running this script in alpine linux images, where bash is not included, but even there it can be easily installed.
In short, I don't see the reason to restrict to sh functionality for benefits that are not clear to me.
@jaromil Lmk what you think!

@Zeioth
Copy link

Zeioth commented Apr 3, 2023

@jaromil What is failing on your end? Could you give more detail? It works fine on my end on all zsh, bash, and sh.

@jaromil
Copy link
Author

jaromil commented Apr 3, 2023

Nothing failing! I have been scripting a lot in zsh and bash, nowadays I wish it would have been all in sh: portable and easier to analyse with stuff like shellcheck. Also BSD systems have native support without installing anything else.

@0xacx
Copy link
Owner

0xacx commented Apr 4, 2023

@jaromil I agree with that but don't you miss some bash functionality that sh doesn't have? A short list of the most important points is here I like and use some of these features in this script.

@jaromil jaromil closed this as completed Apr 5, 2023
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

No branches or pull requests

3 participants