]> git.lizzy.rs Git - plan9front.git/blob - rc/bin/patch/remove
fix mistake
[plan9front.git] / rc / bin / patch / remove
1 #!/bin/rc
2
3 rfork e
4 if(~ $#* 0){
5         echo 'usage: patch/remove patch-name...' >[1=2]
6         exit usage
7 }
8
9 if(! test -d /n/sources/patch){
10         rfork n
11         9fs sources
12 }
13
14 for(i){
15         if(! test -d /n/sources/patch/$i)
16                 echo 'no such patch' /n/sources/patch/$i >[1=2]
17         if not
18                 rm -rf /n/sources/patch/$i
19 }