yNEX
New Member
Hey, I actually signed up just to ask this question I'm trying to solve for around 2 days (18 hours each day perhaps ). I want to copy some files/folders from the Win10-ISO to the Desktop (basically the installation drive) with a batch script. So here's my last solution for this which seems to be almost the correct one (theoretically). Here are the facts.
- Filename I want to copy to Desktop: ExtraISO.7z (~60mb)
- I know its located at this path: \sources\$OEM$\$$\Setup\Files\ExtraISO.7z
- I added my batch.bat file like ExtraISO.7z as a file within the Post-Setup section. So it's located at \sources\$OEM$\$$\Setup\Files\batch.bat too
- My batch.bat contains:
Set src=%~d0
xcopy "%src%\sources\$OEM$\$$\Setup\Files\ExtraISO.7z" "%homedrive%\Users\Public\Desktop\" /Y /F
Explanation:
Set scr=%~d0 --> set a variable called src and %~d0 will get the drive letter where the batch file is executed so I can work with it instead of guessing the drive letter of the installation stick
xcopy "%src%\sources\$OEM$\$$\Setup\Files\ExtraISO.7z" "%homedrive%\Users\Public\Desktop\" /Y /F --> Copies the file ExtraISO.7z to the Public Desktop (Public, because it's the only one which exists when the SetupComplete.cmd get executed; I activated the function to auto-create a user called yNEX with no password.
In my opinion, everything seems to be perfect but I won't copy ANY file/folder ANYwhere. I'm absolutely out of ideas. I even tested the script on my local machine. It works flawless but it doesn't if I use it as Post-Setup.
PS: Does anyone know why ma ISO file size increased from ~3GB to ~8GB? The only difference I can get is that the 8GB one contains a folder called install within the /sources folder. The smaller ISO files don't contain this folder.
- Filename I want to copy to Desktop: ExtraISO.7z (~60mb)
- I know its located at this path: \sources\$OEM$\$$\Setup\Files\ExtraISO.7z
- I added my batch.bat file like ExtraISO.7z as a file within the Post-Setup section. So it's located at \sources\$OEM$\$$\Setup\Files\batch.bat too
- My batch.bat contains:
Set src=%~d0
xcopy "%src%\sources\$OEM$\$$\Setup\Files\ExtraISO.7z" "%homedrive%\Users\Public\Desktop\" /Y /F
Explanation:
Set scr=%~d0 --> set a variable called src and %~d0 will get the drive letter where the batch file is executed so I can work with it instead of guessing the drive letter of the installation stick
xcopy "%src%\sources\$OEM$\$$\Setup\Files\ExtraISO.7z" "%homedrive%\Users\Public\Desktop\" /Y /F --> Copies the file ExtraISO.7z to the Public Desktop (Public, because it's the only one which exists when the SetupComplete.cmd get executed; I activated the function to auto-create a user called yNEX with no password.
In my opinion, everything seems to be perfect but I won't copy ANY file/folder ANYwhere. I'm absolutely out of ideas. I even tested the script on my local machine. It works flawless but it doesn't if I use it as Post-Setup.
PS: Does anyone know why ma ISO file size increased from ~3GB to ~8GB? The only difference I can get is that the 8GB one contains a folder called install within the /sources folder. The smaller ISO files don't contain this folder.