From bae75d95b6ce3af5ac16284a6079ba0feb65cf0b Mon Sep 17 00:00:00 2001 From: Elis Axelsson Date: Thu, 19 Jul 2012 14:56:43 +0200 Subject: Added completions for the fish and fishfish(a fork of fish) shell --- completion/fish_ponysay.fish | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 completion/fish_ponysay.fish (limited to 'completion/fish_ponysay.fish') diff --git a/completion/fish_ponysay.fish b/completion/fish_ponysay.fish new file mode 100644 index 0000000..f0c73a2 --- /dev/null +++ b/completion/fish_ponysay.fish @@ -0,0 +1,24 @@ + +# Completions for ponysay & ponythink +# https://github.com/erkin/ponysay/ +# +# Author: Elis Axelsson + + +if test -d /usr/share/ponysay/ponies/ + set -g systemponies (ls /usr/share/ponysay/ponies/ | sed 's/\.pony/\t Pony from \/usr\/share\/ponysay\/ponies\//') +end + +if test -d ~/.local/share/ponysay/ponies/ + set -g homeponies (ls ~/.local/share/ponysay/ponies/ | sed 's/\.pony/\t Pony from ~\/.local\/share\/ponysay\/ponies\//') +end + +complete -c ponysay -s h --description "Help of ponysay" +complete -c ponysay -s v --description "Version of ponysay" +complete -c ponysay -s l --description "List pony files" +complete -c ponysay -s f -a "$systemponies $homeponies" --description "Select a pony, either a filename or pony name" +complete -c ponysay -s W -a "Integer" --description "The screen column where the message should be wrapped" + +set -e systemponies +set -e homeponies + -- cgit