author | Claus Gittinger <cg@exept.de> |
Mon, 15 Jul 1996 17:07:08 +0200 | |
changeset 123 | a974136fe017 |
parent 119 | 1f4f557d14a4 |
child 165 | bb77927038c7 |
permissions | -rw-r--r-- |
0 | 1 |
"* |
2 |
* $Header$ |
|
5 | 3 |
* |
4 |
* DONT add site specific things here - use your own h_xxx.rc file instead |
|
8 | 5 |
* where xxx stands for your hostname(s) |
5 | 6 |
* |
0 | 7 |
* startup configuration for host specific stuff - |
8 |
* looks for a host specific init file and loads it. |
|
9 |
*" |
|
10 |
||
103
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
11 |
|host domain s| |
0 | 12 |
|
5 | 13 |
(OperatingSystem getSystemType = 'hpux') ifTrue:[ |
14 |
OperatingSystem disableSignal:(OperatingSystem sigALRM) |
|
15 |
]. |
|
16 |
||
103
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
17 |
domain := OperatingSystem getDomainName. |
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
18 |
(domain = 'axept.de' |
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
19 |
or:[domain = 'exept.de']) ifTrue:[ |
119 | 20 |
PostscriptPrinterStream defaultCommands:#( |
21 |
'cat | rsh ibm lpr -h' |
|
103
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
22 |
'cat > preview.ps' |
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
23 |
'cat > preview.ps; ghostview preview.ps' |
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
24 |
). |
119 | 25 |
PostscriptPrinterStream printCommand:'cat | rsh ibm lpr -h'. |
26 |
Printer := PostscriptPrinterStream. |
|
27 |
||
28 |
PrinterStream defaultCommands:#( |
|
29 |
'cat | rsh ibm lpr -h' |
|
30 |
'a2ps | rsh ibm lpr -h' |
|
31 |
'a2ps > preview.ps; ghostview preview.ps' |
|
32 |
). |
|
33 |
PrinterStream printCommand:'cat | rsh ibm lpr -h'. |
|
103
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
34 |
]. |
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
35 |
|
0 | 36 |
host := OperatingSystem getHostName. |
2 | 37 |
host isNil ifTrue:[ |
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
119
diff
changeset
|
38 |
'cannot determine host I am running on' errorPrintCR. |
2 | 39 |
] ifFalse:[ |
0 | 40 |
"if there is a corresponding file ..." |
103
9f5c03497b38
example - checking for the domain
Claus Gittinger <cg@exept.de>
parents:
8
diff
changeset
|
41 |
|
5 | 42 |
(Smalltalk at:#'_ImageHostName') ~= host ifTrue:[ |
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
119
diff
changeset
|
43 |
('trying host setup h_' , host , '.rc ...') infoPrintCR. |
5 | 44 |
|
8 | 45 |
s := Smalltalk systemFileStreamFor:('h_' , host , '.rc'). |
46 |
s notNil ifTrue:[ |
|
47 |
s fileIn. |
|
48 |
s close. |
|
49 |
]. |
|
50 |
Smalltalk at:#'_ImageHostName' put:host. |
|
0 | 51 |
] |
52 |
]. |
|
53 |
! |