summaryrefslogtreecommitdiff
path: root/rc/bin/9fs
diff options
context:
space:
mode:
Diffstat (limited to 'rc/bin/9fs')
-rwxr-xr-xrc/bin/9fs31
1 files changed, 16 insertions, 15 deletions
diff --git a/rc/bin/9fs b/rc/bin/9fs
index 70c496176..796ef79ec 100755
--- a/rc/bin/9fs
+++ b/rc/bin/9fs
@@ -6,6 +6,22 @@ switch($1){
case ''
echo usage: 9fs service '[mountpoint]' >[1=2]
exit usage
+case 9fat
+ part=`{ls /dev/fs/9fat /dev/sd*/9fat >[2]/dev/null}
+ if(~ $#part 0) {
+ echo 'no 9fat partition found' >[1=2]
+ exit no.9fat
+ }
+
+ part=$part(1)
+
+ if(! test -f /srv/dos)
+ dossrv >/dev/null </dev/null >[2]/dev/null
+
+ unmount /n/9fat >/dev/null >[2]/dev/null
+ mount -c /srv/dos /n/9fat $part
+ unmount /n/9 >/dev/null >[2]/dev/null
+ mount -c /srv/dos /n/9 $part
case kfs
if(! test -f /srv/kfs)
disk/kfs
@@ -28,21 +44,6 @@ case sourcesdump
case sourcessnap
9fs sources
mount -n /srv/sources /n/sourcessnap main/snapshot
-# arbitrary venti archives
-case vac:*
- vacfs <{echo $1}
-case *.vac
- if (test -e $1)
- score=$1
- if not if (! ~ $1 /* && test -e $home/lib/vac/$1)
- score=$home/lib/vac/$1
- if not if (! ~ $1 /* && test -e /lib/vac/$1)
- score=/lib/vac/$1
- if not {
- echo $0: $1: no such score file >[1=2]
- exit 'no score file'
- }
- vacfs -m /n/`{basename $1 .vac} `{cat $score}
case wiki
srv -m 'net!plan9.bell-labs.com!wiki' wiki /mnt/wiki
case *