Solaris Advanced Installation Guide

Customizing the Root Environment With a Finish Script

Through a finish script, you can customize files already installed on the system. For example, the finish script in Example 9-2 customizes the root environment by appending information to the .cshrc file in the root directory.


Example 9-2 Customizing the Root Environment With a Finish Script

#!/bin/sh
#
# Customize root's environment
#
echo "***adding customizations in /.cshrc"
test -f a/.cshrc || {
cat >> a/.cshrc <<EOF
set history=100 savehist=200 filec ignoreeof prompt="\$user@`uname -n`> "
alias cp cp -i
alias mv mv -i
alias rm rm -i
alias ls ls -FC
alias h history
alias c clear
unset autologout
EOF
}