Skip to content

Instantly share code, notes, and snippets.

@fourcolors
Created December 4, 2019 23:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fourcolors/953e5895517efcf49b2c5bf3334b3474 to your computer and use it in GitHub Desktop.
Save fourcolors/953e5895517efcf49b2c5bf3334b3474 to your computer and use it in GitHub Desktop.
My fish config
function bx
bundle exec $argv
end
alias fv "nvim (fzf)"
alias v "nvim"
alias vim "nvim"
alias gs "git status"
alias gtl "git log --graph --pretty=oneline --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all"
alias g "git"
alias gco "git checkout"
alias gca "git checkout -a"
alias gl "git log --graph --decorate --pretty=oneline --abbrev-commit --all"
alias nr "nanobox run"
alias n "nanobox"
alias gco "git checkout"
alias gcoa "git checkout -amend"
alias pull "pull --rebase"
alias love "/Applications/love.app/Contents/MacOS/love"
function gcm; git commit -m $argv; end
function gc; git commit; end
function gca; git commit --amend; end
function lh; ls -lah; end
function gclean; git branch -vv | grep 'origin/.*: gone]' | awk '{print $1}' | xargs git branch -d; end
# Make auto complete work with aliases
function make_completion --argument alias command
complete -c $alias -xa "(
set -l cmd (commandline -pc | sed -e 's/^ *\S\+ *//' );
complete -C\"$command \$cmd\";
)"
end
make_completion gco 'git checkout'
#automtically install fisher
if not functions -q fisher
set -q XDG_CONFIG_HOME; or set XDG_CONFIG_HOME ~/.config
curl https://git.io/fisher --create-dirs -sLo $XDG_CONFIG_HOME/fish/functions/fisher.fish
fish -c fisher
end
#enable fish key bindings
# set -U fish_key_bindings fish_vi_key_bindings
# set fish_function_path $fish_function_path "./config//powerline/bindings/fish"
# powerline-setup
# Make node not break when doing tests
ulimit -n 8192
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment