Skip to content

Instantly share code, notes, and snippets.

@morales2k morales2k/.bash_profile

Last active Dec 12, 2017
Embed
What would you like to do?
My entire bash_profile aliases.
#nvm stuff their installer adds
export NVM_DIR=~/.nvm
source $(brew --prefix nvm)/nvm.sh
#nvm stuff end...
#add composer to PATH
export PATH=~/.composer/vendor/bin:$PATH
#aliases to make my life easier
alias phpunit=./vendor/bin/phpunit
alias ngrok=~/ngrok
alias ll="ls -alF"
alias cls="clear"
alias ..="cd .."
alias ...="cd ../.."
alias startvm="homestead up"
alias entervm="homestead ssh"
alias stopvm="homestead suspend"
alias reprovisionvm="homestead reload --provision"
alias vmstatus="homestead global-status"
#i also had another gist for this function only
function artisan() {
if test -f "./artisan"; then
( php artisan $* )
else
printf "\033[0;31mArtisan executable not found in current directory:\n\033[1;33m${PWD}\033[0m\n"
fi
}
# I also had another gist for this function only
function homestead() {
if [ -x $(command -v vagrant) ]
then
( cd ~/Homestead && vagrant $* )
else
if ! [ -x $(command -v vagrant) \) ]; then
printf "\033[0;31mERROR: Vagrant executable is required and was not found.\033[0m\n"
fi
fi
}
# usage: localwebshare yourlocal.app subdomain
# will produce ngrok http yourlocal.app --subdomain="subdomain"
# to be used together with a properly configured homestead VM
function localwebshare() {
( ngrok http $1:80 --subdomain="${2}")
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.