|
DataMuseum.dkPresents historical artifacts from the history of: Regnecentalen RC-900 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Regnecentalen RC-900 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 7042 (0x1b82) Types: TextFile Notes: UNIX file Names: »install«
└─⟦bee8f15db⟧ Bits:30004169/disk2.imd Uniplex II+ V.6 release 1.0 (dansk) └─⟦bee8f15db⟧ UNIX Filesystem └─⟦this⟧ »up/new/usr/UAP/install«
: 'install - Main Uniplex installation script L..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..T..R Usage: UAP/install Exits: undefined ' : Support standard UNIPLEX "-V" argument case "$1" in -V) exec echo "$0: version 6.00";; esac : ' Get something onto users screen as soon as possible - do not want him to lose interest! In normal operation, folling prompt will be followed, after a pause, by the copyright notice ' DEBUG=: export DEBUG : ' UNINAME designed to echo as centred banner. All sub-text should be appropriately aligned ' UNINAME=" ********************************************************* U N I P L E X B U S I N E S S S O F T W A R E *********************************************************" echo " Welcome to$UNINAME " Uredirect=`pwd` cd UAP || exec echo "You must invoke install program as \"UAP/install\"" EXIT=" Terminating Installation" : set defaults for product if test -z "$INFORMIXDIR"; then INFORMIXDIR=/usr/informix fi UNIPLEX_NAME=uniplex UNIPLEX_DIR=/usr/bin export UNIPLEX_NAME UNIPLEX_DIR INFORMIXDIR TMPFILE=/tmp/uinstall$$ trap "rm -f $TMPFILE; exit" 2 3 PATH=$Uredirect/UAP/install.cmds:$Uredirect/UAP/bin:$PATH:/etc PATH=$PATH:$Uredirect/UAP/cmds export Uredirect PATH UNINAME : Check for UID 0 if NOT.superuser; then echo "$EXIT" exit fi umask 0 : 'establish method of no-return after echo' . set.ECHO.args : Now display notice and then check system cat install.cmds/NOTICE echo $EN " Press <RETURN> to continue when you have read the above or *<RETURN> to stop this installation program now: $CEE" read ans case "$ans" in '*') exit 0;; esac : Now check system. Run Checks, abort if any fail. echo " Please wait, UNIPLEX is checking your system and utilities..." check.SHELL || exec echo "$EXIT" check.COMMANDS || exec echo "$EXIT" TERM_DATA=`uinfo -t` export TERM_DATA case "$TERM_DATA" in TERMINFO) check.tic || exec echo "$EXIT";; *) ;; esac echo " UNIPLEX is unpacking any packed files..." find . -name '*.z' -exec unpack {} \; >/dev/null 2>&1 : ' .PA Main menu processing starts here Find default language ' INSLANG="`sed -n 's/^\* *LANGUAGE: *\(.*\)/\1/p' list_of_files 2>/dev/null`" test -z "$INSLANG" && INSLANG='USA english' case "$INSLANG" in USA*) : 'Check in uniplex.sys to see if, on later AOS install, for instance, we actually have UK dates' case "`sed -n '/^DATEFMT/p' uniplex.sys 2>/dev/null`" in *DD/MM/YY*) INSLANG='UK english';; esac ;; esac export INSLANG MSG= while : do : 'now to find what is already installed' eval `check.uins` if test -z "$INSTLD"; then INSTLD=NONE fi if test -z "$UINSTLD"; then : If no modules left to install, default entry is Q DEFANS=q else DEFANS=$UINSTLD fi : ' Set up CHNGDEF to be displayed if BASE is not installed and is available. ' case "$INSTLD" in *1*) CHNGDEF='';; *) CHNGDEF='C - Change defaults';; esac : If BASE not yet installed and INSLANG is USA or UK, allow change option case "$UINSTLD$INSLANG" in 1*USA*) CHNGLANG='L - Change to UK english';; 1*UK* ) CHNGLANG='L - Change to USA english';; * ) CHNGLANG= ;; esac : Add bell to any error message test -z "$MSG" || MSG="$MSG$BELL" echo $EN " $MSG $UNINAME Installation Program - Main Menu Modules Language selected: $INSLANG ======= ================= 1 - Uniplex II Plus Version Six (BASE) $CHNGLANG 2 - Advanced Office System (AOS) 3 - Advanced Graphics System (AGS) Operations ========== $CHNGDEF Q - Quit Modules already installed: $INSTLD available for installation: $UINSTLD NOTE: Enter 123 to install modules 1, 2 and 3 Enter option [$DEFANS]: $CEE" read ans scrap MSG= : If $ans is null substitute default options if test ! -z "$scrap"; then MSG="Invalid Option - \"$ans $scrap\"" continue fi if test -z "$ans"; then ans=$DEFANS fi case "$ans" in [Qq]) exit 0 ;; [Cc]) if test -z "$CHNGDEF"; then MSG="Invalid Option - \"$ans\"" else rm -f $TMPFILE defaults.menu $TMPFILE . $TMPFILE rm -f $TMPFILE fi ;; [Ll]) if test -z "$CHNGLANG"; then MSG="Invalid Option - \"$ans\"" else case "$INSLANG" in UK*) INSLANG='USA english';; US*) INSLANG='UK english';; esac fi ;; [0-9] | [0-9][0-9] | [0-9][0-9][0-9] | [0-9][0-9][0-9][0-9] ) : Sort to-be-insalled option numbers into VALS rm -fr $TMPFILE mkdir $TMPFILE for f in `echo $ans|sed 's/\([1-3]\)/ \1 /g`;do >$TMPFILE/$f done VALS=`cd $TMPFILE; echo ?` rm -fr $TMPFILE : ' The above sed script separates reply into fields so module options can be processed separately, and ensures these options only processed once. Now validate selections: ' case "$INSTLD" in 1*) ONE=1;; *) ONE=;; esac if test -z "$VALS"; then MSG="No option selected" else for i in $VALS; do n=`map.option $i` case "$INSTLD" in *$i*) MSG="Module \"$n\" already installed"; break;; esac case "$UINSTLD" in *$i*) : Selection is in available list ;; *) MSG="Invalid module code - \"$i\""; break;; esac case "$i" in 1) ONE=1;; *) case "$ONE" in 1) ;; *) MSG="Cannot install \"$n\" without BASE"; break;; esac ;; esac done fi : Any error in validation above will set message in MSG non-null if test -z "$MSG"; then : 'Sort/merge installed and to-be-installed option numbers into CONF (contiguous string) and CONFS (space separated list)' rm -fr $TMPFILE mkdir $TMPFILE for f in `echo $VALS $INSTLD|sed 's/\([1-9]\)/ \1 /g`;do >$TMPFILE/$f done CONF=`cd $TMPFILE C= for f in ?; do C=$C$f; done echo $C` CONFS="`cd $TMPFILE; echo ?`" rm -fr $TMPFILE echo install.module $CONF "$CONFS" $VALS echo $EN " Please press <RETURN> to continue$CEE" read resp fi ;; *) MSG="Invalid Option - \"$ans\"" ;; esac done