DataMuseum.dk

Presents historical artifacts from the history of:

ICL Comet 32

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about ICL Comet 32

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download

⟦262248899⟧ TextFile

    Length: 494 (0x1ee)
    Types: TextFile
    Notes: UNIX file
    Names: »hname«

Derivation

└─⟦26887b7e0⟧ Bits:30009717 Comet 32 harddisk image
    └─⟦28c352965⟧ »/a« UNIX Filesystem
        └─⟦this⟧ »sys/build/hname« 

TextFile

#! /bin/sh

model=/sys/build/model/rc

while :
do
	name=`ask hostname "Name ('help' for more info):"`
	case $name in
	quit)
		exit
		;;
	esac
	if echo $name | grep "^[-a-z0-9]*$" > /dev/null
	then
		echo "
Executing: hostname $name"
		if hostname $name > /dev/null
		then
			:
		else
			echo "
Error in hostname command!"
			exit 1
		fi
		echo "Writing /etc/rc file"
		sed -e "s/%hostname/$name/" $model > /etc/rc
		break
	else
		echo "
That's not a good name... try again"
		continue
	fi
done