author | Claus Gittinger <cg@exept.de> |
Fri, 08 Nov 1996 19:46:34 +0100 | |
changeset 168 | cc904c1d1bf3 |
parent 167 | b1b75bc122f3 |
child 180 | 6b0985611def |
permissions | -rw-r--r-- |
4 | 1 |
"* |
2 |
* $Header$ |
|
3 |
* |
|
4 |
* sample private.rc - file |
|
5 |
* |
|
52 | 6 |
* a copy of this file can (should) reside in $home/.smalltalk/private.rc or |
7 |
* in the current directory - put all private preferences in here. |
|
41 | 8 |
* |
9 |
* |
|
25 | 10 |
* notice, you will find some things enclosed in |
143
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
11 |
* ... claus ifTrue:[ |
25 | 12 |
* |
143
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
13 |
* these are my personal preferences which will be |
25 | 14 |
* ignored in your environment, but are taken in mine. |
15 |
* That way, I dont have to maintain two different 'private.rc' files. |
|
143
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
16 |
* (you may want to have a look into it - some is of general interest) |
4 | 17 |
*" |
18 |
||
25 | 19 |
"/ |
167 | 20 |
"/ enable the justInTimeCompiler. |
21 |
"/ This is still somewhat experimental, therefore it is |
|
22 |
"/ turned on maunally here .... |
|
23 |
"/ ... it will be always on, once we have it running for half |
|
24 |
"/ a year or so ;-) |
|
25 |
"/ |
|
168 | 26 |
ObjectMemory justInTimeCompilation:true. |
167 | 27 |
|
28 |
"/ |
|
143
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
29 |
"/ If local sources have preference over source code managment |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
30 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
31 |
"/Class tryLocalSourceFirst:true. |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
32 |
|
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
33 |
"/ |
26 | 34 |
"/ I want the hostname to be prepended to a windows label |
35 |
"/ |
|
36 |
StandardSystemView includeHostNameInLabel:true. |
|
37 |
||
38 |
"/ |
|
25 | 39 |
"/ this turns off error/fatal messages from the VM |
40 |
"/ (it does not really make sense to turn them off) |
|
41 |
"/ |
|
42 |
"/ Smalltalk debugPrinting:false. |
|
43 |
||
44 |
"/ |
|
45 |
"/ set the package for fileIns done below |
|
46 |
"/ |
|
24 | 47 |
Project notNil ifTrue:[ |
48 |
Project setDefaultProject. |
|
25 | 49 |
Project current packageName:#'goody-fileIn'. |
24 | 50 |
]. |
51 |
! |
|
52 |
||
166 | 53 |
|whoAmI thisIsMySystem conf systemType| |
91 | 54 |
|
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
55 |
'reading keyboard.rc ...' infoPrintCR. |
41 | 56 |
Smalltalk fileIn:'keyboard.rc'. |
26 | 57 |
|
58 |
"/ |
|
59 |
"/ no matter what the 'display.rc' says: |
|
60 |
"/ I want my #iris style ... |
|
61 |
"/ |
|
77 | 62 |
View defaultStyle:#iris. |
63 |
"/ View defaultStyle:#motif. |
|
25 | 64 |
|
104 | 65 |
|
66 |
||
25 | 67 |
"/ add my private directories to the searchPath ... |
68 |
"/ This does not make sense in your environment. |
|
69 |
"/ However, I leave the code here to show how its done. |
|
70 |
"/ |
|
24 | 71 |
Smalltalk systemPath addFirst:'../..'. |
72 |
||
91 | 73 |
whoAmI := OperatingSystem getLoginName. |
152 | 74 |
thisIsMySystem := whoAmI = 'claus' or:[whoAmI = 'cg']. |
91 | 75 |
|
152 | 76 |
thisIsMySystem ifTrue:[ |
161 | 77 |
MenuView defaultFont:(MenuView defaultFont size:10). |
78 |
||
26 | 79 |
Smalltalk systemPath addFirst:'../../not_delivered'. |
80 |
Smalltalk systemPath addFirst:'../../private_classes'. |
|
81 |
Smalltalk systemPath addFirst:'../../fileIn/not_delivered'. |
|
25 | 82 |
Smalltalk systemPath addFirst:'../../libpro'. |
16 | 83 |
]. |
25 | 84 |
|
85 |
"/ since smalltalk keeps track of which directories exist |
|
86 |
"/ in the path, this cache has to be flushed whenever new directories |
|
87 |
"/ are added to the path: |
|
88 |
"/ |
|
24 | 89 |
Smalltalk flushPathCaches. |
16 | 90 |
|
25 | 91 |
"/ |
92 |
"/ color allocation strategy: |
|
93 |
"/ |
|
94 |
"/ the default is to allocate from the colormap as required. |
|
95 |
"/ As long as the number of distinct colors used is less than the number |
|
96 |
"/ of available colors (which is usually the case) this leads to better looking |
|
97 |
"/ images. |
|
98 |
"/ However, if many images are to be displayed simulatiously, images displayed |
|
99 |
"/ first may steal too many colors required in images displayed later. |
|
100 |
"/ In this case, it is better to preallocate some colors, and dither all images |
|
101 |
"/ using theese. Of course, while making the worst case better, this makes |
|
102 |
"/ the best case worse. You can decide ... |
|
103 |
"/ |
|
10 | 104 |
"/ Color getColors6x6x4. |
105 |
||
106 |
||
152 | 107 |
"/ The following enables some nice cursors; for example thumbsUp and thumbsDown |
25 | 108 |
"/ |
109 |
"/ claus: |
|
110 |
"/ I like those fancy cursors :-) |
|
111 |
"/ if you think this is too 'childish', remove the line below ... |
|
112 |
"/ |
|
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
113 |
"/ 'loading fancy cursors ...' infoPrintCR. |
118 | 114 |
Cursor initializeNewCursors. |
10 | 115 |
|
25 | 116 |
|
117 |
"/ claus: |
|
26 | 118 |
"/ The history manager automatically adds a history line to changed |
119 |
"/ methods and optionally to a classes history method. |
|
120 |
"/ |
|
152 | 121 |
thisIsMySystem ifTrue:[ |
26 | 122 |
HistoryManager notNil ifTrue:[ |
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
123 |
'activating HistoryManager ...' infoPrintCR. |
26 | 124 |
HistoryManager activate. |
125 |
] |
|
7 | 126 |
]. |
41 | 127 |
|
128 |
"/ claus: |
|
129 |
"/ I dont want those warnings about stx features being non-portable ... |
|
130 |
"/ However, you should (at least when new to the system) see them. |
|
131 |
"/ Once you get bored about them, make the below unconditional. |
|
152 | 132 |
"/ (you can also turn them off in the Launchers settings menu ...) |
41 | 133 |
"/ |
26 | 134 |
Compiler allowUnderscoreInIdentifier:true. |
135 |
Compiler warnUnderscoreInIdentifier:false. |
|
141 | 136 |
Compiler warnSTXSpecials:false. |
10 | 137 |
|
25 | 138 |
|
139 |
"/ this is a temporary kludge: specify the flags to be used |
|
140 |
"/ when compiling via stc. Primitive compilation (from within the browser) |
|
141 |
"/ is still experimental. So you better not care (yet) |
|
152 | 142 |
"/ BTW: its only supported on ELF systems and Linux - anyway |
25 | 143 |
"/ (and not in the free demo release). |
144 |
"/ |
|
166 | 145 |
conf := Smalltalk configuration. |
146 |
(conf includesString:'gcc') ifTrue:[ |
|
147 |
Compiler ccPath:'gcc' |
|
148 |
] ifFalse:[ |
|
149 |
Compiler ccPath:'cc' |
|
150 |
]. |
|
151 |
||
25 | 152 |
Compiler stcCompilation:#default. |
166 | 153 |
Compiler stcCompilationOptions:'+optinline +inlineNew'. |
154 |
||
155 |
"/ special options req'd for some systems (should be done in the host file ...) |
|
152 | 156 |
|
166 | 157 |
systemType := OperatingSystem getOSType. |
158 |
||
159 |
systemType = 'irix' ifTrue:[ |
|
152 | 160 |
Compiler stcCompilationIncludes:'-I../../include'. |
26 | 161 |
Compiler stcCompilationDefines:'-DGLX'. |
10 | 162 |
] ifFalse:[ |
152 | 163 |
Compiler stcCompilationIncludes:'-I../../include -I../../support/VGL/vogl/src'. |
26 | 164 |
Compiler stcCompilationDefines:'-DVGL'. |
165 |
||
152 | 166 |
"/ specify additional link libraries. |
167 |
"/ Disabled; thats the default anyway .... |
|
168 |
"/ |
|
169 |
"/ OperatingSystem getOSType = 'linux' ifTrue:[ |
|
170 |
"/ ObjectFileLoader searchedLibraries:#('/usr/lib/libc.a') |
|
171 |
"/ ] |
|
26 | 172 |
|
25 | 173 |
]. |
7 | 174 |
|
166 | 175 |
Compiler ccCompilationOptions:'-O'. |
176 |
||
177 |
systemType = 'solaris' ifTrue:[ |
|
178 |
Compiler ccCompilationOptions:'-O -fPIC' |
|
179 |
]. |
|
180 |
||
25 | 181 |
"/ experimental: try to always keep some bytes in the pocket |
64 | 182 |
"/ this changes the memory policy, to start the background collector whenever |
25 | 183 |
"/ freespace drops below 250k or 500k have been allocated since the last GC. |
184 |
"/ AND to allocate more memory, if (after the collect) less than 1Mb is free. |
|
185 |
"/ Doing so makes the system behave better if lots of memory is required |
|
64 | 186 |
"/ for short periods of time, since it prepares itself for that situation |
25 | 187 |
"/ during idle time. (I often walk around in the fileBrowser, loading big |
188 |
"/ files like XWorkstation.st or SystemBrowser.st ....) |
|
189 |
"/ |
|
26 | 190 |
ObjectMemory freeSpaceGCAmount:1000000. |
191 |
ObjectMemory freeSpaceGCLimit:250000. |
|
192 |
ObjectMemory incrementalGCLimit:500000. |
|
193 |
ObjectMemory startBackgroundCollectorAt:5. |
|
194 |
ObjectMemory startBackgroundFinalizationAt:5. |
|
25 | 195 |
|
196 |
"/ experimental: configure the memory manager to quickly increase |
|
197 |
"/ its oldSpace, as long as it stays below 8Mb (i.e. do not enter |
|
198 |
"/ a blocking mark&sweep or compress, but go straight ahead increasing |
|
199 |
"/ the oldSpace). Above that, behave as usual, i.e. try a GC first, |
|
200 |
"/ then increase the oldSpace size if that did not help. |
|
201 |
"/ If you have a machine with lots of (real) memory, you may want to |
|
202 |
"/ increase the number. The value below should be ok for 16-32Mb machines. |
|
203 |
"/ |
|
26 | 204 |
ObjectMemory fastMoreOldSpaceLimit:8*1024*1024. |
205 |
ObjectMemory fastMoreOldSpaceAllocation:true. |
|
16 | 206 |
! |
207 |
||
25 | 208 |
"/ another experimental (and a secret for now, since I dont want |
209 |
"/ you to play with those ;-) |
|
210 |
"/ For now, this is experimental. Once the best numbers |
|
211 |
"/ have been found, I'll hardwire them and document it ... |
|
212 |
||
8 | 213 |
|a| |
214 |
ObjectMemory newSpaceSize > (500*1024) ifTrue:[ |
|
215 |
a := #(nil nil nil nil -16 -4 -2 -2 0 0 16 nil) copy. |
|
216 |
] ifFalse:[ |
|
17 | 217 |
"/ min max cpy /32 /16 /8 /4 /2 /4 /8 /16 /32 " |
25 | 218 |
"/ |
219 |
"/ slow tenure - keeps objects longer in newSpace, |
|
220 |
"/ producing more scavenge overhead, but releasing IGC somewhat |
|
221 |
"/ |
|
17 | 222 |
"/ a := #(nil nil nil -100 -8 -4 -1 1 2 4 8 16 nil) copy. |
223 |
"/ a := #(nil nil nil nil -16 -4 0 0 0 4 16 nil) copy. |
|
25 | 224 |
|
17 | 225 |
"fast tenure" |
25 | 226 |
"/ |
227 |
"/ fast tenure - moves objects earlier into oldSpace, |
|
228 |
"/ releasing newSpace collector; however, the oldSpace IGC |
|
229 |
"/ may have more work to do. |
|
230 |
"/ |
|
16 | 231 |
a := #(nil nil nil nil -20 -8 -3 -1 -1 1 16 nil) copy. |
8 | 232 |
]. |
233 |
ObjectMemory tenureParameters:a. |
|
25 | 234 |
|
235 |
||
236 |
"/ set the package back to some useful default for programming |
|
237 |
"/ this is the package token assigned (by default) to all new methods/classes |
|
238 |
"/ (so you can use a browser on package=#private to find all of your new |
|
239 |
"/ stuff easily. (the conditional on Project being nonNil is for stripped down |
|
240 |
"/ systems without a Project class) |
|
241 |
||
242 |
Project notNil ifTrue:[ |
|
243 |
Project setDefaultProject. |
|
244 |
Project current packageName:#'private'. |
|
245 |
]. |
|
8 | 246 |
! |
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
247 |
|
126 | 248 |
(Smalltalk commandLine includes:'-q') ifFalse:[ |
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
249 |
"/ |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
250 |
"/ this turns off/on information messages from classes |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
251 |
"/ (such as 'D8IMAGE: allocating colors ...' |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
252 |
"/ |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
253 |
"/ Object infoPrinting:false. |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
254 |
Object infoPrinting:true. |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
255 |
|
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
256 |
"/ |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
257 |
"/ this turns off/on information messages from the VM |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
258 |
"/ (such as 'MEM: chitty chatty ...' |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
259 |
"/ |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
260 |
"/ ObjectMemory infoPrinting:false. |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
261 |
ObjectMemory infoPrinting:true. |
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
262 |
]. |
143
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
263 |
|
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
264 |
Smalltalk addStartBlock:[ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
265 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
266 |
"/ start some views ... |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
267 |
"/ you can add all stuff you'd like to come up by default |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
268 |
"/ the first time. |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
269 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
270 |
|
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
271 |
'starting main-menu ...' infoPrintCR. |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
272 |
Launcher open |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
273 |
|
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
274 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
275 |
"/ start a SystemBrowser |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
276 |
"/ - I dont want one (using Launcher) |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
277 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
278 |
"/ SystemBrowser open. |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
279 |
|
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
280 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
281 |
"/ start a FileBrowser |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
282 |
"/ - I dont want one (using Launcher) |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
283 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
284 |
"/ FileBrowser open. |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
285 |
|
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
286 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
287 |
"/ start a Workspace |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
288 |
"/ - I dont want one (using Launcher) |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
289 |
"/ |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
290 |
"/ Workspace open. |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
291 |
]. |
71dc5ec7ef26
Renamed NewLauncher to Launcher.
Stefan Vogel <sv@exept.de>
parents:
141
diff
changeset
|
292 |
|
123
a974136fe017
startup infoPrinting suppressable (-q flag)
Claus Gittinger <cg@exept.de>
parents:
118
diff
changeset
|
293 |
! |