Skip to content

Conversation

@pFragga
Copy link

@pFragga pFragga commented Aug 19, 2025

Removed bashisms that made the file unable to be run by tmux on systems where /bin/sh is a symlink to dash. Shell commands in tmux are sh commands. It only worked if your system symlinked /bin/sh to bash.

To make the file even more POSIX-compliant, we would have to remove the local variable assignments on lines 29-31, but dash supports these builtins, so this should be fine.

I used the tool checkbashisms on Arch Linux to locate the issues.

Removed bashisms that made the file unable to be run by tmux on systems
where `/bin/sh` is a symlink to `dash`.  Shell commands in `tmux` are
`sh` commands.  It only worked if your system symlinked `/bin/sh` to
`bash`.

To make the file even more POSIX-compliant, we would have to remove the
`local` variable assignments on lines 29-31, but `dash` supports these
builtins, so this should be fine.

I used the tool `checkbashisms` on Arch Linux to locate the issues.
@pFragga pFragga requested a review from svengreb as a code owner August 19, 2025 10:34
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