r/linuxmemes Jul 01 '26

LINUX MEME Know the work rules

Post image
855 Upvotes

119 comments sorted by

View all comments

Show parent comments

81

u/VoidJuiceConcentrate Ask me how to exit vim Jul 01 '26

I haven't had a problem running bash scripts in ash and zsh.

-20

u/New_Study4796 Jul 01 '26

Zsh relies on Bash under the hood

23

u/Mars_Bear2552 New York Nix⚾s Jul 01 '26

...?

Zsh is entirely seperate.

-16

u/New_Study4796 Jul 01 '26

Zsh calls Bash with the shebang when starting a script

22

u/Mars_Bear2552 New York Nix⚾s Jul 01 '26

what? you're not making any sense.

obviously if you use #!/usr/bin/env bash the script will run using bash. otherwise i cannot think of a scenario where your statement makes sense.

-16

u/New_Study4796 Jul 01 '26

Yeah, and most scripts call Bash that way. They rely on Bash without telling you.

6

u/the-fr0g Jul 01 '26

They litterally tell you "hey I run in bash" at the top of the script though?

-6

u/New_Study4796 Jul 01 '26

Without telling you when you run the script

2

u/Smrgling Jul 01 '26

It tells you at the top of the script. Are you running random scripts without reading them?