./etc/utmp minix-sys
./home minix-sys
./home/ast minix-sys
-./home/ast/.ashrc minix-sys
./home/ast/.exrc minix-sys
./home/ast/.profile minix-sys
./home/bin minix-sys
-./home/bin/.ashrc minix-sys
./home/bin/.exrc minix-sys
./home/bin/.profile minix-sys
./lib minix-sys
./multiboot/mod06_memory minix-sys
./proc minix-sys
./root minix-sys
-./root/.ashrc minix-sys
./root/.exrc minix-sys
./root/.profile minix-sys
./sbin minix-sys
./usr/adm minix-sys
./usr/adm/old minix-sys
./usr/ast minix-sys
-./usr/ast/.ashrc minix-sys
./usr/ast/.exrc minix-sys
./usr/ast/.profile minix-sys
./usr/benchmarks minix-sys
+++ /dev/null
-# Ash initialization.
-
-test -z "$EDITOR" && { # Don't repeat in subshells.
-
-umask 022
-
-# Favourite editor and pager, search path for binaries, etc.
-export EDITOR=vi
-export PAGER=less
-export PATH=$HOME/bin:/usr/local/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/pkg/bin:/usr/pkg/sbin:/usr/pkg/X11R6/bin
-
-} # End of no-repeat.
-
-# Let cd display the current directory on the status line.
-if [ -t 0 -a -f /usr/bin/tget ] && tget -flag hs
-then
-case $- in *i*)
- hostname=$(expr $(uname -n) : '\([^.]*\)')
- eval "cd()
- {
- chdir \"\$@\" &&
- echo -n '$(tget -str ts \
- "$USER@$hostname:'\"\`pwd\`\"'" \
- -str fs)'
- }"
- unset hostname
- cd .
- ;;
-esac
-fi
# Login shell profile.
-# Activate emacs keybindings and command line history support
-set -o emacs
+umask 022
+
+# Favourite editor and pager, search path for binaries, etc.
+export EDITOR=vi
+export PAGER=less
+
+# Let cd display the current directory on the status line.
+if [ -t 0 -a -f /usr/bin/tget ] && tget -flag hs
+then
+case $- in *i*)
+ hostname=$(expr $(uname -n) : '\([^.]*\)')
+ eval "cd()
+ {
+ chdir \"\$@\" &&
+ echo -n '$(tget -str ts \
+ "$USER@$hostname:'\"\`pwd\`\"'" \
+ -str fs)'
+ }"
+ unset hostname
+ cd .
+ ;;
+esac
+fi
# Check terminal type.
case $TERM in
TERM="${term:-$TERM}"
unset term
esac
-
-# Shell configuration.
-unset EDITOR; . $HOME/.ashrc
-RC_TZ=/etc/rc.timezone
+# Default system-wide login shell profile.
+
+# Activate emacs keybindings and command line history support
+set -o emacs
+
+# Set the default path
+PATH=/usr/local/bin:/usr/pkg/bin:/usr/bin:/bin
+
+# Add ~/bin, iff it is present
+if [ -e ${HOME}/bin ]; then
+ PATH=${HOME}/bin:${PATH}
+fi
+
+# Add sbin for root
+if [ "x$(id -u)" = "x0" ]; then
+ PATH=/usr/local/sbin:/usr/pkg/sbin:/usr/sbin:/sbin:${PATH}
+
+ if [ -e ${HOME}/sbin ]; then
+ PATH=${HOME}/sbin:${PATH}
+ fi
+fi
+
+# Set the timezone
export TZ=GMT0
-if [ -f "$RC_TZ" ]
-then . "$RC_TZ"
+RC_TZ=/etc/rc.timezone
+
+if [ -f ${RC_TZ} ]; then
+ . ${RC_TZ}
fi
+
+export PATH TZ
+
exec </dev/null
umask 022
-FSTAB=/etc/fstab
-TERM="${TERM-minix}"
-PATH=/usr/local/bin:/bin:/usr/bin:/usr/sbin:/usr/pkg/bin:/usr/pkg/sbin:/sbin
+
+# Same settings as in the default /etc/profile. We do not source this file
+# as the system administrator may decide to change those values for his users.
RC_TZ=/etc/rc.timezone
+PATH=/usr/local/sbin:/usr/pkg/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/pkg/bin:/usr/bin:/bin
+
+# Set TERM to minix if not present.
+TERM="${TERM-minix}"
+
export TERM PATH
+# Local variables
ARCH="`sysenv arch`"
-if [ ! "$ARCH" ]
-then # Older kernels do not provide an arch sysenv variable.
- # We assume we are on x86 then, as existing systems with
- # kernel and userland (i.e. this script) unsynchronized
- # will be x86.
- ARCH=i386
-fi
-
usage()
{
echo >&2 "Usage: $0 [-saf] start|stop|down"
service $opt edit /usr/sbin/$service -label $service "$@"
}
-# This function parses the deprecated minix shellscript-style
-# /etc/fstab, and fscks and mounts its filesystems.
-mountfstab_poorman()
-{
- echo "WARNING: old fstab format, please upgrade!"
-
- # /etc/fstab lists the root, home, and usr devices.
- . $FSTAB
-
- intr fsck.mfs $fsckopts $usr
- if [ ! -z "$home" ]
- then intr fsck.mfs $fsckopts $home
- fi
-
- # mount /usr
- mount $bin_img $usr /usr
-
- if [ ! -z "$home" ]
- then mount $bin_img $home /home || echo "WARNING: couldn't mount $home on /home"
- fi
-}
-
while getopts 'saf' opt
do
case $opt in
mount -r $usrdev /usr
else
# If we're not booting from CD, fsck + mount using /etc/fstab.
- read <$FSTAB fstabline
- if [ "$fstabline" = "# Poor man's File System Table." ]
- then mountfstab_poorman # Old minix /etc/fstab
- else fsck -x / $fflag $fsckopts
- mount -a
- fi
+ fsck -x / $fflag $fsckopts
+ mount -a
fi
# Unmount and free now defunct ramdisk
# Get the device table.
FSTAB=/etc/fstab
touch $FSTAB
-if grep -q "Poor man" $FSTAB
-then . $FSTAB
-else root="`awk <$FSTAB '{ if($2=="/") { print $1 } }'`"
-fi
+root="`awk <$FSTAB '{ if($2=="/") { print $1 } }'`"
# The real root device may be the RAM disk.
realroot=`printroot -r`
dd if=/dev/zero seek=$BLOCKS of=$fsimage count=1 bs=$BS >/dev/null 2>&1
# -s keeps modes
-mkproto -s -b $BLOCKS -i $INODES $testdir >$protofile
+/usr/sbin/mkproto -s -b $BLOCKS -i $INODES $testdir >$protofile
-mkfs.mfs -T 1 -b $BLOCKS -i $INODES $fsimage $protofile >/dev/null 2>&1
+/sbin/mkfs.mfs -T 1 -b $BLOCKS -i $INODES $fsimage $protofile >/dev/null 2>&1
sum="`sha1 $fsimage | awk '{ print $4 }'`"
if [ $sum != $expect ]