diff options
Diffstat (limited to 'rc/bin/inst/copydist')
-rwxr-xr-x | rc/bin/inst/copydist | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/rc/bin/inst/copydist b/rc/bin/inst/copydist new file mode 100755 index 000000000..507d5602b --- /dev/null +++ b/rc/bin/inst/copydist @@ -0,0 +1,31 @@ +#!/bin/rc + +# prereq: mountdist +# desc: copy the distribution into the file system + +switch($1){ +case checkready + if(! test -d /n/dist/dist/replica){ + copydist=notdone + export copydist + exit + } + if(test -f /n/newfs/dist/replica/didplan9){ + copydist=done + export copydist + exit + } +case go + inst/watchfd applylog 0 `{ls -l /n/dist/dist/replica/plan9.log | awk '{print $6}'} 'Installing file system' & + replica/pull -c / /rc/bin/inst/replcfg + if(~ $status '' *conflicts || test -f /n/newfs/dist/replica/didplan9witherrors) + >/n/newfs/dist/replica/didplan9 + if not + >/n/newfs/dist/replica/didplan9witherrors + +case checkdone + if(! test -f /n/newfs/dist/replica/didplan9){ + copydist=notdone + export copydist + } +} |