Skip to content

Instantly share code, notes, and snippets.

@JenniferNorthrup
Created May 31, 2018 02:46
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JenniferNorthrup/0a8f890b64ab9256bf292398e6b0e38f to your computer and use it in GitHub Desktop.
Save JenniferNorthrup/0a8f890b64ab9256bf292398e6b0e38f to your computer and use it in GitHub Desktop.
Bash Profile
#!/bin/bash
# Bash Profile
# By JenniferNorthrup
# Aliases
alias new="~/../../Program\ Files/Git/git-bash"
# Old DOS command aliases
alias dir="ls"
alias md="mkdir"
alias cd..="cd .."
alias chdir="pwd"
alias copy="cp"
alias move="mv"
alias cls="clear"
alias del="rm"
alias find="grep"
alias edit="vi"
alias mem="use"
#Should be the command name
alias rename="mv"
alias showme="curl"
alias goget="curl -o"
# Script shortcuts
alias prof="vi ~/.bash_profile"
alias src="source ~/.bash_profile"
# Functions
#echo mcd: Makes a directory and cd\'s into it
mcd(){
mkdir $1
cd $1
}
#echo sp: See port
sp(){
lsof -i :$1
}
#echo kp: Kill port
kp(){
lsof -i :$1 -t
}
#echo deproxify: Removes npm proxy
#deproxify(){
# npm config rm proxy
# npm config rm https-proxy
# npm set registry=https://registry.npmjs.org
#}
#proxify(){
# npm config proxy=http://proxy.goes.here
# npm config https-proxy=https://https-proxy.goes.here
# npm set registry=https://internal.registry.goes.here
#}
# Aliases for notes
alias bashguide="echo http://www.tldp.org/LDP/abs/html/abs-guide.html"
alias vimcheatsheet="echo https://www.reddit.com/r/vim/comments/32r85c/this_is_my_favorite_vim_cheat_sheet_does_anyone/ OR http://i.imgur.com/YLInLlY.png"
alias tryprolog="echo https://bernardopires.com/2013/10/try-logic-programming-a-gentle-introduction-to-prolog/"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment