inst/prepdisk: fix invocations of test(1)
Test(1) was fixed some time ago [1] to properly parse all of its
command line arguments. As such, we need to be more careful about
using test(1) with globbing patterns.
[1] changeset b562b269ce
This commit is contained in:
parent
3cf83fa259
commit
51669adf24
1 changed files with 4 additions and 2 deletions
|
@ -14,7 +14,8 @@ fn autotype {
|
||||||
|
|
||||||
switch($1) {
|
switch($1) {
|
||||||
case checkready
|
case checkready
|
||||||
if(! test -f /dev/sd*/plan9*){
|
disks=(/dev/sd*/plan9*)
|
||||||
|
if(! test -f $disks(1)){
|
||||||
prepdisk=notdone
|
prepdisk=notdone
|
||||||
export prepdisk
|
export prepdisk
|
||||||
}
|
}
|
||||||
|
@ -43,7 +44,8 @@ case go
|
||||||
disk/prep -p $disk >`{basename -d $disk}^/ctl >[2]/dev/null
|
disk/prep -p $disk >`{basename -d $disk}^/ctl >[2]/dev/null
|
||||||
|
|
||||||
case checkdone
|
case checkdone
|
||||||
if(! test -f /dev/sd*/9fat)
|
disks=(/dev/sd*/9fat)
|
||||||
|
if(! test -f $disks(1))
|
||||||
prepdisk=ready
|
prepdisk=ready
|
||||||
if(! ~ $prepdisk ready)
|
if(! ~ $prepdisk ready)
|
||||||
prepdisk=done
|
prepdisk=done
|
||||||
|
|
Loading…
Reference in a new issue