Skip to content

Instantly share code, notes, and snippets.

@ricalo
Last active April 20, 2017 04:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ricalo/dea79f9553c1d348c37ec4e927e26d7e to your computer and use it in GitHub Desktop.
Save ricalo/dea79f9553c1d348c37ec4e927e26d7e to your computer and use it in GitHub Desktop.
Update file permissions in Git. Useful when you have to upload scripts to your CI/CD
// source: http://stackoverflow.com/questions/10516201/updating-file-permissions-only-in-git
git ls-tree HEAD
git update-index --chmod=+x script.sh
git commit
git checkout script.sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment