refactor: automate erasing variables in uninstall

This commit is contained in:
Jorge Bucaran 2019-01-12 19:10:04 +09:00
parent 81f03702e6
commit f1766dcfa0
No known key found for this signature in database
GPG key ID: E54BA3C0E646DB30
2 changed files with 4 additions and 5 deletions

View file

@ -281,7 +281,7 @@ end
## Uninstalling
You want to know how to uninstall Fisher and everything you've installed with it from your system. This command will purge all packages, cache, configuration and related files—all in the same session.
You want to know how to uninstall Fisher and everything you've installed with it from your system. This command will purge all packages, cache, configuration and related files.
```fish
fisher self-uninstall

View file

@ -188,10 +188,9 @@ function _fisher_self_uninstall
command rm -Rf $file 2>/dev/null
end | command sed "s|$HOME|~|" >&2
set -e fisher_cache
set -e fisher_config
set -e fisher_path
set -e fisher_version
for name in (set -n | command awk '/^fisher_/')
set -e "$name"
end
complete -c fisher --erase
functions -e (functions -a | command awk '/^_fisher/') fisher