2 Rem Make a WISE Installer distribution list, where each file is represented by
3 Rem a section like this:
6 Rem Source=d:\wx2\thefile.txt
7 Rem Destination=%MAINDIR%\thefile.txt
8 Rem Flags=0000000000000010
11 Rem Generate a list of all files in the distribution.
12 dir /BS
>& %TEMP
\files
1.tmp
14 Rem Now we iterate through the list of files, writing out the middle section of
16 Rem We have to remove the first part of the path,
17 Rem by truncating the start by the size of the current directory.
19 set sz
=%@EVAL
[%@LEN
[%_CWD
]+1]
20 set len
=%@LINES
[%TEMP
\files
1.tmp
]
22 erase /Y
%TEMP
\files
2.tmp
24 Rem, first add system files
25 cat
%WXWIN\distrib\msw\wisesys.txt
> %temp
\files
2.tmp
28 set line
=%@LINE
[%TEMP
\files
1.tmp
,%i
]
32 set n
=%@EVAL
[%sz2
-%sz
]
33 set line2
=%@SUBSTR
[%line
,%sz
,%n
]
35 Rem
Echo the file section
36 echo item
: Install File
>> %TEMP
\files
2.tmp
37 echo Source
=%line
>> %TEMP
\files
2.tmp
38 echo Destination
=%%MAINDIR%%\
%line2
>> %TEMP
\files
2.tmp
39 echo Flags
=0000000000000010 >> %TEMP
\files
2.tmp
40 echo end >> %TEMP
\files
2.tmp
43 Rem Concatenate the 3 sections
44 cat
%WXWIN\distrib\msw\wisetop.txt
%TEMP
\files
2.tmp
%WXWIN\distrib\msw\wisebott.txt
> %WXWIN\distrib\msw\wxwin2.wse
46 erase /Y
%TEMP
\files
1.tmp
47 rem erase /Y %TEMP\files2.tmp