Merge branch 'master' of gitlab.com:tyrelsouza/dotfiles
This commit is contained in:
commit
ef338dbf97
39
bash_aliases
39
bash_aliases
@ -2,7 +2,7 @@
|
|||||||
export HOMEBREW_GITHUB_API_TOKEN="caf4cd85c6eb6ddcf006d4571d4a294c0b0592e4"
|
export HOMEBREW_GITHUB_API_TOKEN="caf4cd85c6eb6ddcf006d4571d4a294c0b0592e4"
|
||||||
alias ag='\ag --pager="less"'
|
alias ag='\ag --pager="less"'
|
||||||
alias cg='cd "$(git rev-parse --show-toplevel)"'
|
alias cg='cd "$(git rev-parse --show-toplevel)"'
|
||||||
alias fuck='eval $(thefuck $(fc -ln -1)); history -r'
|
alias fuck='eval $(thefuck $(fc -ln -1)); \history -r'
|
||||||
alias g='git'
|
alias g='git'
|
||||||
alias pdb="python -m pdb"
|
alias pdb="python -m pdb"
|
||||||
alias ppjson="python -m json.tool"
|
alias ppjson="python -m json.tool"
|
||||||
@ -12,7 +12,7 @@ alias adocs='cd $ADDGENE_CORE_REPO_DIR/docs && make html && open $ADDGENE_CORE_R
|
|||||||
alias deploy_all="fab -R silver-web deploy:master && fab -R gold-web deploy:master && fab -R jupyter fab -R jupyter deploy_jupyter && fab --parallel avail_staging_hosts deploy:master"
|
alias deploy_all="fab -R silver-web deploy:master && fab -R gold-web deploy:master && fab -R jupyter fab -R jupyter deploy_jupyter && fab --parallel avail_staging_hosts deploy:master"
|
||||||
alias deploy_all_migration="fab -R silver-web deploy:master,1 && fab -R gold-web deploy:master,1 && fab -R jupyter deploy_jupyter & fab --parallel avail_staging_hosts deploy:master,1"
|
alias deploy_all_migration="fab -R silver-web deploy:master,1 && fab -R gold-web deploy:master,1 && fab -R jupyter deploy_jupyter & fab --parallel avail_staging_hosts deploy:master,1"
|
||||||
alias aenv='env | sort | grep ADDGENE'
|
alias aenv='env | sort | grep ADDGENE'
|
||||||
alias sl='source local.env'
|
alias sl="source local.env.$(basename $SHELL)"
|
||||||
|
|
||||||
if [[ $OSTYPE == darwin* ]]; then
|
if [[ $OSTYPE == darwin* ]]; then
|
||||||
alias rm=trash;
|
alias rm=trash;
|
||||||
@ -45,4 +45,39 @@ function cpbr () {
|
|||||||
}
|
}
|
||||||
function hidden() { ls -a "$@" | grep '^\.'; }
|
function hidden() { ls -a "$@" | grep '^\.'; }
|
||||||
|
|
||||||
|
alias shrug="echo -n '¯\_(ツ)_/¯' | pbcopy"
|
||||||
|
|
||||||
|
function h () {
|
||||||
|
if [ -z "$*" ]
|
||||||
|
then
|
||||||
|
history
|
||||||
|
else
|
||||||
|
history | egrep "$@"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ -n "$SSH_CLIENT" ] || [ -n "$SSH_TTY" ]; then
|
||||||
|
export PS1="<ssh>$PS1"
|
||||||
|
fi
|
||||||
|
alias stabbats='sudo killall VDCAssistant && open https://appear.in/stab-bats'
|
||||||
|
|
||||||
|
|
||||||
|
function GitHub()
|
||||||
|
{
|
||||||
|
git_url=`git config --get remote.origin.url`
|
||||||
|
if [[ $git_url == https://github* ]];
|
||||||
|
then
|
||||||
|
url=${git_url%.git}
|
||||||
|
else
|
||||||
|
if [[ $git_url == git@github.com* ]]
|
||||||
|
then
|
||||||
|
url="https://github.com/${${git_url:15}%.git}"
|
||||||
|
else
|
||||||
|
echo "ERROR: Remote origin is invalid" && return false;
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
open $url
|
||||||
|
}
|
||||||
|
|
||||||
|
alias github=GitHub
|
||||||
|
|
||||||
|
7
bin/resolv_work.sh
Executable file
7
bin/resolv_work.sh
Executable file
@ -0,0 +1,7 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
cp /etc/resolv.conf /home/tyrelsouza/prev_resolv.conf
|
||||||
|
|
||||||
|
echo > /etc/resolv.conf
|
||||||
|
echo "nameserver 10.0.2.22" >> /etc/resolv.conf
|
||||||
|
echo "search addgene.org" >> /etc/resolv.conf
|
@ -11,11 +11,15 @@
|
|||||||
interactive = auto
|
interactive = auto
|
||||||
[push]
|
[push]
|
||||||
default = current
|
default = current
|
||||||
|
[fetch]
|
||||||
|
prune = true
|
||||||
[format]
|
[format]
|
||||||
pretty = format:%C(auto)%h %C(green)%G? %C(red)%<(15,trunc)%aN %C(cyan)%<(15,trunc)%ar %C(white)%<(60,trunc)%s %C(auto)%d
|
pretty = format:%C(auto)%h %C(green)%G? %C(red)%<(15,trunc)%aN %C(cyan)%<(15,trunc)%ar %C(white)%<(60,trunc)%s %C(auto)%d
|
||||||
[alias]
|
[alias]
|
||||||
# show all these aliases
|
# show all these aliases
|
||||||
alias = "!git config -l | grep alias | cut -c 7-"
|
alias = "!git config -l | grep alias | cut -c 7-"
|
||||||
|
# delete all merged branches
|
||||||
|
bc = !git branch --merged master | grep -v master | xargs git branch -d
|
||||||
# Way more information on git log
|
# Way more information on git log
|
||||||
ll = log --stat --abbrev-commit
|
ll = log --stat --abbrev-commit
|
||||||
# Show files modified per commit
|
# Show files modified per commit
|
||||||
@ -37,6 +41,7 @@
|
|||||||
pr = !"pr() { git fetch origin pull/$1/head:pr-$1; git checkout pr-$1; }; pr"
|
pr = !"pr() { git fetch origin pull/$1/head:pr-$1; git checkout pr-$1; }; pr"
|
||||||
# Diff so fancy!
|
# Diff so fancy!
|
||||||
dsf = "!f() { [ \"$GIT_PREFIX\" != \"\" ] && cd "$GIT_PREFIX"; git diff --color $@ | diff-so-fancy | less --tabs=4 -RFX; }; f"
|
dsf = "!f() { [ \"$GIT_PREFIX\" != \"\" ] && cd "$GIT_PREFIX"; git diff --color $@ | diff-so-fancy | less --tabs=4 -RFX; }; f"
|
||||||
|
scrum = log --since='1 day ago' --author='Tyrel Souza' --oneline
|
||||||
[filter "lfs"]
|
[filter "lfs"]
|
||||||
clean = git-lfs clean %f
|
clean = git-lfs clean %f
|
||||||
smudge = git-lfs smudge %f
|
smudge = git-lfs smudge %f
|
||||||
|
@ -1,3 +1,7 @@
|
|||||||
import sys
|
import sys
|
||||||
import pprint
|
import pprint
|
||||||
sys.displayhook = pprint.pprint
|
sys.displayhook = pprint.pprint
|
||||||
|
try:
|
||||||
|
import pdir
|
||||||
|
except ImportError:
|
||||||
|
pass
|
||||||
|
1
zshrc
1
zshrc
@ -3,7 +3,6 @@ plugins=(git sudo github django python pip cp vagrant virtualenv nmap rvm)
|
|||||||
if [ -n "$SSH_CLIENT" ] || [ -n "$SSH_TTY" ]; then
|
if [ -n "$SSH_CLIENT" ] || [ -n "$SSH_TTY" ]; then
|
||||||
ZSH_THEME="soliah"
|
ZSH_THEME="soliah"
|
||||||
else
|
else
|
||||||
ZSH_THEME="candy"
|
|
||||||
ZSH_THEME="tyrel"
|
ZSH_THEME="tyrel"
|
||||||
export VIRTUAL_ENV_DISABLE_PROMPT=1
|
export VIRTUAL_ENV_DISABLE_PROMPT=1
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user