A good SetupComplete.cmd script is not complex to write.
It is just a batch script that will execute anything you put into it such as a silent installer, for example: 'install /s /locale=en-us'.
It should be placed in a folder called '$OEM$\$$\Setup\Scripts' ('$$' translates to 'C:\Windows') under 'sources' in your installation disk.

But if you want a nice good script to use, here is the one I wrote for Windows 7:

First it sets global vars for root setup folder, installation software folders (%~dp0 = Current working Dir) and RunOnceEx register path.
These scripts will first check your systems locale to see if it is Dutch (can be extended for more locales), else it chooses English.
Based on the locale, it will change the language of the script and command parameters so it fits better for the user.

Then it will open a prompt for 5 seconds which allow you to cancel (Y) or continue (N) modifications.
If you let it continue, it will add registry keys to enable runonceex which will open a dialog on first login and add additional entries which will execute the programs and scripts of your choice.

After adding registry keys it will execute a program called 'get_win8key' which will do one thing, which is output contents of MSDN table (embedded product key).
The script will parse the output in a for loop and send the key to 'slmgr.vbs', the CLI activation program of Windows.

I recommend naming your script 'oobe.cmd' so it will execute in OOBE, thus before product key verification part so the script will activate Windows if key exists in BIOS and skip product key verification.
This is handy since you can now add ei.cfg and choose all 8.1 or 10 versions and not have to deal with auto activation since the script will fix this.

Well that was a mouthfull, hopefully this has helped you ^_^.
If you want I can also send you a link with the contents of my $OEM$ folder I add to my ISO's.

Have a nice day.

Visit my script repo for scripts that might make your life easier or more fascinating.

Stop hovering to collapse...Click to collapse...Hover to expand...Click to expand...