fish: add '--plain' option to fish_colors function

This commit is contained in:
Charles Gould 2020-03-21 21:57:49 -05:00
parent 8b2ec9ef34
commit f3eb75a432

View File

@ -1,5 +1,14 @@
function fish_colors --description 'Print the fish color variables' function fish_colors --description 'Print the fish color variables'
set --local plain 0
if contains -- '--plain' $argv
set plain 1
end
for i in (set -n | string match 'fish*_color*') for i in (set -n | string match 'fish*_color*')
echo $i (set_color $$i)$$i(set_color normal) if test $plain -eq 1
echo $i $$i
else
echo $i (set_color $$i)$$i(set_color normal)
end
end end
end end