Skip to content

Instantly share code, notes, and snippets.

@hisaichi5518
Created July 9, 2014 07:23
Show Gist options
  • Save hisaichi5518/1273f4ead3b37a1b558d to your computer and use it in GitHub Desktop.
Save hisaichi5518/1273f4ead3b37a1b558d to your computer and use it in GitHub Desktop.
function peco-src() {
local selected_dir=$(ghq list --full-path | peco --query "$LBUFFER")
if [ -n "$selected_dir" ]; then
cd ${selected_dir}
fi
}
zle -N peco-src
bindkey '^S' peco-src
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment