Add fish configuration functions
This commit is contained in:
parent
6c8ad380dd
commit
1096fab497
@ -12,7 +12,6 @@ alias deploy_all="fab -R silver-web deploy:master && fab -R gold-web deploy:mas
|
|||||||
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'
|
||||||
unalias mysql
|
|
||||||
|
|
||||||
if [[ $OSTYPE == darwin* ]]; then
|
if [[ $OSTYPE == darwin* ]]; then
|
||||||
alias rm=trash;
|
alias rm=trash;
|
||||||
|
3
config/config.fish
Normal file
3
config/config.fish
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
set fish_greeting ''
|
||||||
|
eval (python -m virtualfish)
|
||||||
|
|
4
config/fish/functions/adg.fish
Normal file
4
config/fish/functions/adg.fish
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
function adg
|
||||||
|
vf activate addgene-core
|
||||||
|
cd ~/code/github/addgene/addgene-core
|
||||||
|
end
|
31
config/fish/functions/fish_prompt.fish
Normal file
31
config/fish/functions/fish_prompt.fish
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
function fish_prompt --description 'Write out the prompt'
|
||||||
|
# virtualenv stuff
|
||||||
|
if set -q VIRTUAL_ENV
|
||||||
|
echo -n -s (set_color -b blue white) "(" (basename "$VIRTUAL_ENV") ")" (set_color normal) " "
|
||||||
|
end
|
||||||
|
set -l last_status $status
|
||||||
|
|
||||||
|
if not set -q __fish_prompt_normal
|
||||||
|
set -g __fish_prompt_normal (set_color normal)
|
||||||
|
end
|
||||||
|
|
||||||
|
# PWD
|
||||||
|
set_color $fish_color_cwd
|
||||||
|
echo -n (prompt_pwd)
|
||||||
|
set_color normal
|
||||||
|
|
||||||
|
printf '%s ' (__fish_git_prompt)
|
||||||
|
|
||||||
|
if not test $last_status -eq 0
|
||||||
|
set_color $fish_color_error
|
||||||
|
end
|
||||||
|
|
||||||
|
# Set a pretty date
|
||||||
|
set_color -b black yellow
|
||||||
|
echo -n '['(date "+%I:%M %P")']'
|
||||||
|
set_color normal
|
||||||
|
|
||||||
|
echo -n ' $ '
|
||||||
|
|
||||||
|
set_color normal
|
||||||
|
end
|
Loading…
Reference in New Issue
Block a user