mirror of
https://github.com/oh-my-fish/oh-my-fish.git
synced 2025-02-02 21:36:15 +08:00
Source uninstall.fish
file before emitting event
Instead of having every plugin function inside the same file, which increases the loading time unnecessarily and is not fishy, source the `uninstall.fish` file for the plugin before the `uninstall_$plugin_name` event is emitted.
This commit is contained in:
parent
b4aa5a4408
commit
520d597947
|
@ -15,7 +15,7 @@ function omf.remove_package
|
|||
for path in {$OMF_PATH,$OMF_CONFIG}/{pkg}/$pkg
|
||||
not test -d $path; and continue
|
||||
|
||||
emit uninstall_$pkg
|
||||
source $path/uninstall.fish; and emit uninstall_$pkg
|
||||
omf.bundle.remove "package" $pkg
|
||||
|
||||
rm -rf $path
|
||||
|
|
Loading…
Reference in New Issue
Block a user