| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Multiple Config.sys |
William Geiger wrote in a message to William Geiger: WG> Hi All , Yes it's me again WG> Does anyone know of a better way of handling multiple WG> config.sys files for OS/2? Right now I am using the Alt-F1 WG> while OS/2 is loading then selecting the config.sys file I WG> wan't to use. This is rather cumbersome for keeping track of WG> changes between the different config.sys files. Back in the WG> DOS days I could set up menu options inside of my config.sys WG> for different configurations. Is this option available for WG> OS/2? I could not find it in the docs. I've written a rexx script to do this, but unlike someone's earlier post, mine works from a 'master' config file, so lines common to different config setups are only entered once. Here it is, if it's any use: ------------------------------------------------------------------------------- /* Config.Sys Selection program */ ConfigFile="c:\os2\util\config.tpt" say "Enter configuration selection" pull Selection sel=translate(Selection) OutFile="c:\config.sys" linein(ConfigFile,,0) del OutFile do while lines(ConfigFile) thisline = linein(Configfile) units=words(sqline) oneword=translate(word(thisline,1)) if ((translate(word(thisline,1))="REM")&(translate(word(thisline,2))="SELECT")) then do if wordpos(sel,translate(thisline))=0 then do cflag=0 end else do cflag=1 end end else do if cflag=1 then call lineout OutFile,thisline end end exit ------------------------------------------------------------------------------- Change the second line to reflect the filename of the configuration 'template' you wish to use, ie. the master config file. Next choose a name for each different config setup you want. In your master config file, put lines with the keywords "rem select" followed by the name(s) of the setup(s), to enable the lines following for the target config.sys. Then when you want to change the setup, run the rexx script, and enter the setup name when prompted. A config.sys file will be created from the master file according to which setup you want, and next time you reboot, the new config will take force. All sounds a bit complex, but i'll give an example which should clear things up: rem sample master config file rem select basic protshell=c:\os2\util\tshell.exe rem select normal protshell=c:\os2\pmshell.exe set runworkplace=c:\os2\pmshell.exe rem select basic normal device=c:\boot\com.sys . . . when you run the script, just enter normal for a wps environment, or basic for a text only environment. PS. does anyone know how to access command line paramaters from a REXX script? I used pull for the above script because i couldn't figure it out. Cheers, --- timEd/2-B10* Origin: Sure to Rise, Te Waipounamu (NZ) (3:770/115.15) SEEN-BY: 50/99 78/0 620/243 622/407 623/630 632/339 690/347 711/409 410 413 SEEN-BY: 711/430 808 809 934 955 712/515 713/888 770/115 116 135 155 215 345 SEEN-BY: 770/510 771/1320 772/1 20 135 350 380 774/605 800/1 7877/2809 @PATH: 770/115 772/20 711/955 808 809 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.