xref: /plan9/sys/lib/dist/pc/sub/a: (revision 9a747e4fd48b9f4522c70c07e8f882a15030f964)
1#!/bin/rc
2if(! test -f /srv/dos)
3	dossrv >/dev/null </dev/null >[2]/dev/null
4unmount /n/a:>[2]/dev/null
5
6if(~ $#adisk 1)
7	;	# do nothing
8if not if(~ $#bootfile 0)
9	adisk=/dev/fd0disk
10if not {
11	switch($bootfile) {
12	case sd*
13		adisk=`{echo $bootfile | sed 's#(sd..).*#/dev/\1/data#'}
14	case fd*
15		adisk=`{echo $bootfile | sed 's#(fd.).*#/dev/\1disk#'}
16	case *
17		echo 'unknown bootfile '^$bootfile^'; mail 9trouble@plan9.bell-labs.com'
18		exit oops
19	}
20}
21
22mount -c /srv/dos /n/a: $adisk
23