diff --git a/files/fish/config.fish b/files/fish/config.fish index 000b930..58e4f60 100644 --- a/files/fish/config.fish +++ b/files/fish/config.fish @@ -10,3 +10,7 @@ export PATH="$PATH:$GOPATH/bin:$GOROOT/bin:$HOME/.cargo/bin" # The next line updates PATH for the Google Cloud SDK. if [ -f '$HOME/Desktop/google-cloud-sdk/path.fish.inc' ]; . '$HOME/Desktop/google-cloud-sdk/path.fish.inc'; end + +# tabtab source for packages +# uninstall by removing these lines +[ -f ~/.config/tabtab/fish/__tabtab.fish ]; and . ~/.config/tabtab/fish/__tabtab.fish; or true diff --git a/files/tabtab/fish/__tabtab.fish b/files/tabtab/fish/__tabtab.fish new file mode 100644 index 0000000..4990a5c --- /dev/null +++ b/files/tabtab/fish/__tabtab.fish @@ -0,0 +1,4 @@ + +# tabtab source for pnpm package +# uninstall by removing these lines +[ -f ~/.config/tabtab/fish/pnpm.fish ]; and . ~/.config/tabtab/fish/pnpm.fish; or true diff --git a/files/tabtab/fish/pnpm.fish b/files/tabtab/fish/pnpm.fish new file mode 100644 index 0000000..2b6c322 --- /dev/null +++ b/files/tabtab/fish/pnpm.fish @@ -0,0 +1,22 @@ +###-begin-pnpm-completion-### +function _pnpm_completion + set cmd (commandline -o) + set cursor (commandline -C) + set words (count $cmd) + + set completions (eval env DEBUG=\"" \"" COMP_CWORD=\""$words\"" COMP_LINE=\""$cmd \"" COMP_POINT=\""$cursor\"" pnpm completion -- $cmd) + + if [ "$completions" = "__tabtab_complete_files__" ] + set -l matches (commandline -ct)* + if [ -n "$matches" ] + __fish_complete_path (commandline -ct) + end + else + for completion in $completions + echo -e $completion + end + end +end + +complete -f -d 'pnpm' -c pnpm -a "(_pnpm_completion)" +###-end-pnpm-completion-### diff --git a/install.conf.yaml b/install.conf.yaml index bf0864c..82c161b 100644 --- a/install.conf.yaml +++ b/install.conf.yaml @@ -1,17 +1,18 @@ - defaults: - link: - create: true - relink: true - force: true + link: + create: true + relink: true + force: true - clean: ["~"] - link: - ~/.gitconfig: files/git/gitconfig - ~/.vim: files/vim - ~/.vimrc: files/vimrc - ~/.config/fish: files/fish - ~/.config/omf: files/omf + ~/.gitconfig: files/git/gitconfig + ~/.vim: files/vim + ~/.vimrc: files/vimrc + ~/.config/fish: files/fish + ~/.config/omf: files/omf + ~/.config/tabtab: files/tabtab - shell: - - [git submodule update --init --recursive, Installing submodules] + - [git submodule update --init --recursive, Installing submodules]