Skip to content

Instantly share code, notes, and snippets.

@ashleyblackmore
Forked from netmarkjp/envwrapper.sh
Created January 16, 2014 00: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 ashleyblackmore/8447407 to your computer and use it in GitHub Desktop.
Save ashleyblackmore/8447407 to your computer and use it in GitHub Desktop.
#!/bin/sh
# from http://d.hatena.ne.jp/heavenshell/20121122/1353597292
VENV=$1
echo $VENV
if [ -z $VENV ]; then
echo "usage: runinenv [virtualenv_path] CMDS"
exit 1
fi
. ${VENV}/bin/activate
shift 1
echo "Executing $@ in ${VENV}"
exec "$@"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment