Add utility script to run cargo clean in a dir

main
trivernis 2 years ago
parent 2561ad7aa6
commit 86b54db197
Signed by: Trivernis
GPG Key ID: DFFFCC2C7A02DB45

@ -0,0 +1,15 @@
#!/bin/nu
def main [
dir: string # The directory that contains the rust projects
] {
echo $"Cleaning ($dir)"
(
ls $dir
| get name
| where ($it | ls $it | where name =~ 'Cargo.toml' | length ) > 0
| par-each { cd $in; cargo clean }
| ignore
)
echo $"($dir) cleaned"
}
Loading…
Cancel
Save