dot.profile revision 1.7
11.7Ssalo# $NetBSD: dot.profile,v 1.7 2003/07/26 17:06:41 salo Exp $ 21.1Sthorpej# 31.1Sthorpej# Copyright (c) 1995 Jason R. Thorpe 41.1Sthorpej# Copyright (c) 1994 Christopher G. Demetriou 51.1Sthorpej# All rights reserved. 61.1Sthorpej# 71.1Sthorpej# Redistribution and use in source and binary forms, with or without 81.1Sthorpej# modification, are permitted provided that the following conditions 91.1Sthorpej# are met: 101.1Sthorpej# 1. Redistributions of source code must retain the above copyright 111.1Sthorpej# notice, this list of conditions and the following disclaimer. 121.1Sthorpej# 2. Redistributions in binary form must reproduce the above copyright 131.1Sthorpej# notice, this list of conditions and the following disclaimer in the 141.1Sthorpej# documentation and/or other materials provided with the distribution. 151.1Sthorpej# 3. All advertising materials mentioning features or use of this software 161.1Sthorpej# must display the following acknowledgement: 171.6Scgd# This product includes software developed for the 181.7Ssalo# NetBSD Project. See http://www.NetBSD.org/ for 191.6Scgd# information about NetBSD. 201.1Sthorpej# 4. The name of the author may not be used to endorse or promote products 211.6Scgd# derived from this software without specific prior written permission. 221.6Scgd# 231.1Sthorpej# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 241.1Sthorpej# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 251.1Sthorpej# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 261.1Sthorpej# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 271.1Sthorpej# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 281.1Sthorpej# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 291.1Sthorpej# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 301.1Sthorpej# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 311.1Sthorpej# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 321.1Sthorpej# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 331.6Scgd# 341.6Scgd# <<Id: LICENSE,v 1.2 2000/06/14 15:57:33 cgd Exp>> 351.1Sthorpej 361.1SthorpejPATH=/sbin:/bin:/usr/bin:/usr/sbin:/ 371.1Sthorpejexport PATH 381.1SthorpejTERM=hp300h 391.1Sthorpejexport TERM 401.2SperryHOME=/ 411.2Sperryexport HOME 421.1Sthorpej 431.1Sthorpejumask 022 441.1Sthorpej 451.1Sthorpejif [ "X${DONEPROFILE}" = "X" ]; then 461.1Sthorpej DONEPROFILE=YES 471.3Scgd export DONEPROFILE 481.1Sthorpej 491.1Sthorpej # set up some sane defaults 501.1Sthorpej echo 'erase ^H, werase ^W, kill ^U, intr ^C' 511.1Sthorpej stty newcrt werase ^W intr ^C kill ^U erase ^H 9600 521.1Sthorpej 531.1Sthorpej # get the terminal type 541.1Sthorpej _forceloop="" 551.1Sthorpej while [ "X${_forceloop}" = X"" ]; do 561.1Sthorpej eval `tset -s -m ":?$TERM"` 571.1Sthorpej if [ "X${TERM}" != X"unknown" ]; then 581.1Sthorpej _forceloop="done" 591.1Sthorpej fi 601.1Sthorpej done 611.1Sthorpej 621.1Sthorpej # Installing or upgrading? 631.1Sthorpej _forceloop="" 641.1Sthorpej while [ "X${_forceloop}" = X"" ]; do 651.1Sthorpej echo -n '(I)nstall or (U)pgrade? ' 661.1Sthorpej read _forceloop 671.1Sthorpej case "$_forceloop" in 681.1Sthorpej i*|I*) 691.1Sthorpej /install 701.1Sthorpej ;; 711.1Sthorpej 721.1Sthorpej u*|U*) 731.1Sthorpej /upgrade 741.1Sthorpej ;; 751.1Sthorpej 761.1Sthorpej *) 771.1Sthorpej _forceloop="" 781.1Sthorpej ;; 791.1Sthorpej esac 801.1Sthorpej done 811.1Sthorpejfi 82