diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2019-03-20 15:55:57 -0700 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2019-03-20 15:55:57 -0700 |
| commit | e665d9725c4bb02f4c18d16527367f424cb880fa (patch) | |
| tree | aed161ee6b338c2bad2312591f746459414ccafa /lib/tools/uninstall.nom | |
| parent | 606fd090002f3d545cbd58440e96624907846f45 (diff) | |
Auto-updated to 7.0.0 syntax and removed some shims.
Diffstat (limited to 'lib/tools/uninstall.nom')
| -rwxr-xr-x | lib/tools/uninstall.nom | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/lib/tools/uninstall.nom b/lib/tools/uninstall.nom index 90a8477..f5dbaa3 100755 --- a/lib/tools/uninstall.nom +++ b/lib/tools/uninstall.nom @@ -1,5 +1,6 @@ -#!/usr/bin/env nomsu -V6 -# +#!/usr/bin/env nomsu -V7.0.0 + +### A tool to uninstall third party Nomsu packages (the inverse of the install tool) Usage: @@ -23,16 +24,16 @@ use "shell" command line program with $args: $searchpath = - [ - : for $ in ["?.lua", "?/init.lua", "?.nom", "?/init.nom"]: + [: + for $ in ["?.lua", "?/init.lua", "?.nom", "?/init.nom"]: add "\$(NOMSU PACKAGEPATH)\$" ], joined with ";" - + for $package_name in $args.extras: $path = ($package.searchpath $package_name $package.nomsupath "/") unless $path: say "Sorry, couldn't find \$package_name in \$(NOMSU PACKAGEPATH)" exit 1 $path = ($path, with "/init%.nom" -> "") - unless ((ask "Do you want to delete \$path? [Y/n] ") == "n"): - run command "rm -rv \$path" + unless ((ask "Do you want to delete \($path)? [Y/n] ") == "n"): + run command "rm -rv \$path"
\ No newline at end of file |
