I wanted to create one slipstream code which is more universal and it can be used to slipstream updates for Windows 7, Windows Server 2008 R2 and Windows 8.1. In usually tend to keep all scripts on github but all windows iso and update files are located on google drive for example in
c:\g\w:
In this project, I wanted for the code to be as short as possible. One way how to accomplish this goal is to create an application which is a lot based on directory names. For example, I can look the exact name of windows version which I am working on with the command:
dism /get-wiminfo /wimfile:c:\iso\sources\install.wim /index:1 | find "Name "
This can output names like:
Name : Windows 7 ULTIMATE
Name : Windows Server 2008 R2 SERVERDATACENTER
Name : Windows 8.1 Pro
Later based on these names i look for directory names like these to take content and automatically work with:
Since Windows 7 x64 needs pretty much the same content as Windows Server 2008 R2 i have to figure out how let these booth operating systems take content from same directory. I solve this problem with Windows version number:
dism /get-wiminfo /wimfile:c:\iso\sources\install.wim /index:1 | find "Version "
This will output content like:
6.1.7601
6.3.9600
6.1.7601 is for Windows 7 and Server 2008 R2
6.3.9600 is for Windows 8.1:
All files together:
All other non-selected files is just the profiles how i can quickly just choose one of the interested operating systems for example if i want to create Windows 7 Professional x64 edition i run:
call "%~dp0slipstream.cmd" C:\g\w\X17-59186.iso C:\g\w\u6.1.7601x64 3 c:
slipstream.cmd need to get four parameters:
%1 - file location to the iso file
%2 - directory where the updates are having a good time
%3 - index number i want to work with
%4 - output directory for new iso file
none of the parameters supports spaces or quotes!
Here is the main program:
No comments:
Post a Comment