This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
description: "asdf", | |
duration: "1m", | |
exam_required: false, | |
frequency_id: 1, | |
is_active: false, | |
name: "bob", | |
test_questions: Array(1) [ | |
0:{question_text: "Whga", | |
required: true, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function check_for_virtual_env { | |
[ -d .git ] || git rev-parse --git-dir &> /dev/null | |
if [ $? -eq 0 ]; then | |
local ENV_NAME=`basename \`pwd\`` | |
if [ "${VIRTUAL_ENV##*/}" != $ENV_NAME ] && [ -e $WORKON_HOME/$ENV_NAME/bin/activate ]; then | |
workon $ENV_NAME && export CD_VIRTUAL_ENV=$ENV_NAME | |
fi | |
elif [ $CD_VIRTUAL_ENV ]; then |