summaryrefslogtreecommitdiff
path: root/rc/bin/9fs
diff options
context:
space:
mode:
authorstanley lieber <stanley.lieber@gmail.com>2011-04-22 20:14:08 +0000
committerstanley lieber <stanley.lieber@gmail.com>2011-04-22 20:14:08 +0000
commit609e1466c5736b369e169c37aab094cd61249b8e (patch)
tree6c27597a1d36e0c0d7c944af92aa430422462663 /rc/bin/9fs
parentc693f26b2c5e54fda92e827be8ae0c92fe98a725 (diff)
downloadplan9front-609e1466c5736b369e169c37aab094cd61249b8e.tar.xz
9fs: add 9fat, remove venti/vac
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 *