PageRenderTime 11ms CodeModel.GetById 1ms app.highlight 5ms RepoModel.GetById 1ms app.codeStats 0ms

/share/examples/nwclient/nwfs.sh.sample

https://bitbucket.org/freebsd/freebsd-head/
Shell | 34 lines | 21 code | 3 blank | 10 comment | 3 complexity | db18f16d8ee22b6f672bf93d3788eba3 MD5 | raw file
 1#!/bin/sh
 2#
 3# $FreeBSD$
 4#
 5# Location: /usr/local/etc/rc.d/nwfs.sh
 6#
 7# Simple script to mount NetWare volumes at startup.
 8# It assumes that all mount points described in fstab file and password
 9# entries listed in /root/.nwfsrc file. See mount_nwfs(8) for details.
10#
11
12mount=/sbin/mount
13umount=/sbin/umount
14HOME=/root; export HOME
15vols="/nw/sys /nw/vol1"
16
17if [ "x$1" = "x" -o "x$1" = "xstart" ]; then
18	echo -n "Mounting NetWare volumes: "
19	for vol in ${vols}; do
20		$mount $vol
21		echo -n "$vol "
22	done
23	echo "Done"
24elif [ "x$1" = "xstop" ]; then
25	echo -n "Unmounting NetWare mount points: "
26	for vol in ${vols}; do
27		$umount $vol
28		echo -n "$vol "
29	done
30	echo "Done"
31else
32	echo "Unknown command $1"
33fi
34