oh-my-fish/pkg/omf/cli/omf.destroy.fish
Bruno Pinto 20ed43983b Naming functions with omf. namespace.
Having a clear namespace `omf.` improves the readability of the code as
we clarify what is the function name and what is the namespace.
2015-08-28 18:24:56 +09:00

16 lines
351 B
Fish

function omf.destroy -d "Remove Oh My Fish"
echo (omf::dim)"Removing Oh My Fish..."(omf::off)
omf.remove_package (basename $OMF_PATH/pkg/*) >/dev/null ^&1
if test -e "$HOME/.config/fish/config.copy"
mv "$HOME/.config/fish/config".{copy,fish}
end
if test "$OMF_PATH" != "$HOME"
rm -rf "$OMF_PATH"
end
exec fish < /dev/tty
end