I stopped setting up Windows by hand, and one text file now does the whole install for me

I stopped setting up Windows by hand, and one text file now does the whole install for me

Published Sep 26, 2026, 9:00 AM EDT Gaming has been Samarveer’s greatest passion, and the Literature graduate in him takes immense joy in dissecting games for their themes, messages, and impact. Samarveer holds a deep appreciation of gaming, and considers the platform to be the most immersive and impactful across all media. He can be found engaging with gaming communities online, always ready to debate the finer points of ray tracing or itching to write an 8-page collegiate thesis on any game that impacts him emotionally. Every year, without fail, I run into at least five or six instances where I need to reinstall Windows 11, either on my PC when something goes incredibly wrong, or when I need to help out a friend nuke their own PC and start anew. At this point, however, I'm pretty tired of the entire process I have to sit through — there's too much friction involved, with about a million prompts to click on and decisions to make before finally reaching the desktop. Truth be told, none of this is difficult, but at this point, the whole ritual has begun feeling rather pointless. I've gotten tired of babysitting Windows installations, so I decided to see how much of the process I could eliminate. Turns out, Windows can handle most of it automatically, and I just have to set things up once and forget it. Now, when I need a fresh Windows installation, I just let it happen while I grab a cup of coffee. I built my own unattended Windows installer Schneegans' Generator made the complicated part surprisingly simple I started with Schneegans' Windows Answer File Generator, which is easily the least intimidating way I've found to build an autounattend.xml file without manually wrestling with Microsoft's answer-file syntax. I worked through the generator and configured the basics first. I chose to generate a .cmd script to handle the Windows PE stage, which is the recommended option for VMs as well. For the Windows edition, I chose the Pro edition, and ensured that the setup bypasses the Windows 11 requirements check. For the express settings, I chose the Disable all option. I paid particular attention to the disk configuration. Automating partitioning is wonderfully convenient when the target machine is known, but it can also turn a useful installer into a very efficient way of deleting the wrong drive. For a USB drive I'm going to carry between machines, I wanted Windows to automate the setup without making assumptions about hardware I hadn't seen yet. Once the XML was generated, I downloaded a fresh Windows 11 ISO directly from Microsoft rather than modifying some random image from the internet. I then opened the ISO in AnyBurn, loaded the Windows 11 image and edited it, adding the autounattend.xml file to the root of the image. After saving the modified ISO, my setup was completely ready, and so was my virtual drive. The next job was proving that those instructions actually worked. I tested the installer before trusting it with anyone's PC Hyper-V gave me the answer I was looking for Before I put this ISO on a USB drive and started using it on real machines, I wanted to make sure I hadn't accidentally created a very efficient Windows installation disaster. Hyper-V was the obvious place to test it. I created a new Generation 2 Virtual Machine, gave it enough RAM and storage for Windows 11 (100 GB if you're wondering), attached the modified ISO to its virtual DVD drive, and configured the VM to boot from that drive. While 4GB RAM and 64GB storage space is usually enough for the Virtual Machine, try increasing it to 8GB RAM during setup for a smoother experience, and 100 GB storage to avoid any conflicts with the autounattend.xml configuration file. I also made sure the virtual machine had the hardware Windows 11 expects, including Secure Boot and a virtual TPM. After all, there's very little point in testing an unattended Windows 11 installer in a configuration that doesn't resemble the machines you're actually going to install it on. After starting the VM, Hyper-V asked me whether I wanted to boot from the DVD, and the single button press I made to confirm it was my final contribution to the installation. Everything else was handled by Windows from then on. The next thing I saw was the Windows 11 desktop, with the user already logged in and the machine ready to use. Now I carry my own Windows installation with me One modified ISO saves me from doing the same work over and over Once I knew the installer worked, I put that modified ISO onto the bootable USB drive I keep with me. It now functions as something far more useful than a standard Windows installer. Whenever I need to reinstall Windows 11, I already have an installation image configured the way I want it, instead of starting from Microsoft's default setup and working through the same screens every single time. If a friend's PC needs a clean Windows installation, or I'm helping troubleshoot a laptop that has become sufficiently unhappy with itself, I can plug in the drive and let Windows handle the tedious part. I still need to make sure I'm installing onto the correct machine and drive, but I don't need to babysit the installation. All I've really done is remove a pile of repetitive clicks from something I've done countless times. Now, one single XML file does the boring work, and I can get on with everything I actually want my freshly-installed PC for. Windows 11 Pro A USB installation drive and license key for Windows 11 Pro, with additional features like Hyper-V and Windows Sandbox support. Setting up a new PC is now the easiest (and quickest) part of the process for me This setup doesn't eliminate every single decision involved in reinstalling an OS, but it ensures I never have to make those decisions twice. I've now managed to remove myself from a process that was never all that interesting to begin with. Windows installation, by no means, is difficult, but it sure was boring and repetitive. Install Windows enough times and the same screens start to feel like filling out the same form at the DMV for the tenth time. That's ultimately what I like about this little setup. It doesn't eliminate every single decision involved in reinstalling an entire OS, but it does mean that I've made those decisions once, deliberately, and I'll never have to make them again. That's the perfect form of automation for something as routine as a fresh Windows installation.

Original Source

Read the full article at Xda-developers →

KhanList aggregates and links to publicly available news content. We do not host full articles from third-party sources. Always verify important information with original sources.