diff --git a/fish/config.fish b/fish/config.fish index 2161003..8a7b0cc 100644 --- a/fish/config.fish +++ b/fish/config.fish @@ -11,6 +11,7 @@ if status is-interactive alias la="exa -lha --git --no-user" alias nv="foreground_nvim" alias gr="gh repo clone" + alias glz="lazygit" # Exported Variables set -gx PATH ~/.local/bin $PATH diff --git a/fish/functions/ghpr.fish b/fish/functions/ghpr.fish new file mode 100644 index 0000000..8cf0fc2 --- /dev/null +++ b/fish/functions/ghpr.fish @@ -0,0 +1,7 @@ +# credit to https://github.com/helix-editor/helix/discussions/5883 +function ghpr + GH_FORCE_TTY=100% gh pr list --limit 300 | \ + fzf --ansi --preview 'GH_FORCE_TTY=100% gh pr view {1}' --preview-window 'down,70%' --header-lines 3 | \ + awk '{print $1}' | \ + xargs gh pr checkout +end