Skip to content

Instantly share code, notes, and snippets.

@chuckadams
Created April 27, 2020 21:14
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 chuckadams/fe3c84669e1a15b8d7a36b2e4a44306e to your computer and use it in GitHub Desktop.
Save chuckadams/fe3c84669e1a15b8d7a36b2e4a44306e to your computer and use it in GitHub Desktop.
#!/bin/sh
if [ -z $1 ]; then
stamp=$(mktemp /tmp/stamp.XXXXXXXX)
trap 'rm $stamp' EXIT
emacs $HOME/bin
find $HOME/bin/ -type f -cnewer $stamp | xargs -r chmod +x
exit 0
fi
bin=$HOME/bin/$1
emacs $bin
chmod +x $bin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment