Skip to content

Instantly share code, notes, and snippets.

@mattmccray
Forked from jdonaldson/hxn.sh
Last active December 16, 2015 01:09
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 mattmccray/5352573 to your computer and use it in GitHub Desktop.
Save mattmccray/5352573 to your computer and use it in GitHub Desktop.
export OLDPATH=$PATH
export HAXE_NIGHTLY=$HOME/bin/haxe_nightly
export USE_HAXE_NIGHTLY=false
hxn(){
if [ -z "$USE_HAXE_NIGHTLY" ] || $USE_HAXE_NIGHTLY; then
echo "Changing to Haxe stable version"
export HAXE_STD_PATH=$OLD_HAXE_STD
export PATH=$OLDPATH
export USE_HAXE_NIGHTLY=false
else
echo "Changing to Haxe nightly at: $HAXE_NIGHTLY"
export OLD_HAXE_STD=$HAXE_STD_PATH
export HAXE_STD_PATH=$HAXE_NIGHTLY/haxe/std:.
export OLDPATH=$PATH
export PATH=$HAXE_NIGHTLY/haxe:$HAXE_NIGHTLY/neko:$PATH
export USE_HAXE_NIGHTLY=true
fi
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment