File tree 1 file changed +15
-0
lines changed
1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -103,6 +103,21 @@ export def "zvm remove" [
103
103
echo $" Successfully removed Zig ($zig_to_remove.version )"
104
104
}
105
105
106
+ # Remove unused versions
107
+ export def "zvm clean" [] {
108
+ let versions_to_remove = zvm list -- system | where active == false | get version
109
+ if ($versions_to_remove | is-empty ) {
110
+ print " No unused version to remove"
111
+ return
112
+ }
113
+
114
+ let path_prefix = get_or_create_path_prefix
115
+ for v in $versions_to_remove {
116
+ rm -- recursive -- permanent $" ($path_prefix )/($v )"
117
+ }
118
+ echo $" Successfully removed the following unused versions:\n ($versions_to_remove )"
119
+ }
120
+
106
121
def verify_signature [temp_dir : string , tarball : string ] {
107
122
http get $" ($tarball ).minisig" | save $" ($temp_dir )/($tarball | path basename ).minisig"
108
123
You can’t perform that action at this time.
0 commit comments