Skip to content

Instantly share code, notes, and snippets.

@crusj
Last active July 19, 2019 10:20
Show Gist options
  • Save crusj/6c250c038865d4170dc764abc85f118b to your computer and use it in GitHub Desktop.
Save crusj/6c250c038865d4170dc764abc85f118b to your computer and use it in GitHub Desktop.
set normal (set_color normal)
set magenta (set_color magenta)
set yellow (set_color yellow)
set green (set_color green)
set red (set_color red)
set gray (set_color -o black)
# Fish git prompt
set __fish_git_prompt_showdirtystate 'yes'
set __fish_git_prompt_showstashstate 'yes'
set __fish_git_prompt_showuntrackedfiles 'yes'
set __fish_git_prompt_showupstream 'yes'
set __fish_git_prompt_color_branch yellow
set __fish_git_prompt_color_upstream_ahead green
set __fish_git_prompt_color_upstream_behind red
# Status Chars
set __fish_git_prompt_char_dirtystate '⚡'
set __fish_git_prompt_char_stagedstate '→'
set __fish_git_prompt_char_untrackedfiles '☡'
set __fish_git_prompt_char_stashstate '↩'
set __fish_git_prompt_char_upstream_ahead '+'
set __fish_git_prompt_char_upstream_behind '-'
function fish_prompt
set last_status $status
set_color $fish_color_cwd
printf '%s' (prompt_pwd)
set_color normal
printf '%s ' (__fish_git_prompt)
set_color normal
end
# Path
set PATH $PATH /home/jianglong/Bin/go/bin /snap/bin /home/jianglong/bin /home/jianglong/.local/bin /home/jianglong/go/bin
set -x GOPATH /home/jianglong/go
set -x GOROOT /home/jianglong/Bin/go
set -x MICRO_API_HANDER rpc
set -x MICRO_NAMESPACE go.micro.srv
set -x GDLV_NORMAL_FONT Monospaced
set -x GDLV_BOLD_FONT Monospaced
set -x QT_DIR /home/jianglong/Qt5.13.0
set -x QT_VERSION 5.13.0
set -x QT_API 5.13.0
set -x LD_LIBRARY_PATH /usr/lib64
set GTAGSLABEL pygments
#vi mode
fish_vi_key_bindings
########################################## alias exa
alias lsdir "ls -l | grep '^d'"
alias ld lazydocker
alias le "exa -l"
alias lea "exa --across"
alias leg "le --long --git"
########################################## alias cd
# go/src
alias gtg "cd $GOPATH/src"
# ~/Project
alias gtp "cd $HOME/Project"
# ~/Downloads
alias gtd "cd $HOME/Downloads"
# ~
alias gth "cd ~"
########################################## alias vim
# fish.config
alias vfish "vim ~/.config/fish/config.fish"
# spacevim init.toml
alias vspace "vim ~/.SpaceVim.d/init.toml"
########################################## alias go
# build main.go
alias gbm "go build main.go"
########################################## alias 无道词典
alias ws "wd -s"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment