Skip to content

Change shebang for greater portability #185

Description

@Jekotia

I'm currently trialing nixos, and have encountered a script portability problem: the shebang being used in this project will not resolve to a sh binary because sh isn't present at the assumed path /bin/sh.

Researching shebangs and portability, I have found that #! /usr/bin/env sh is considered to be the most portable. In basic terms, this shebang uses /usr/bin/env to check the locations in the $PATH variable for sh. This means that, so long as sh is available in a users' $PATH, it will find and run the correct binary.

I was going to fork and make a pull request, but I imagine that a pull request touching every single script in this repository is likely to cause problems with other dev's working trees when they try and merge their changes, hence this being raised as an issue instead. If I am mistaken, I will happily fork and create a pull request for this change.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions