Skip to content

Instantly share code, notes, and snippets.

@monking
Created March 17, 2015 22:43
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 monking/f90e16d5d76dfe0e4021 to your computer and use it in GitHub Desktop.
Save monking/f90e16d5d76dfe0e4021 to your computer and use it in GitHub Desktop.
run `codecept` from anywhere in your git repo
# Runs codeception wherever you are in a git repo
# include this file in your shell with `. /path/to/codecept.sh`
function codecept() {
local cwd root
cwd="$(pwd)"
cd "./$(git rev-parse --show-cdup)"
root="$(pwd)"
"$root/vendor/codeception/codeception/codecept" $@ -c "$root"
cd "$cwd"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment