I tend to reinstall windows every month with the help of chocolatey.
# install chocolatey
Set-ExecutionPolicy Bypass -Scope Process -Force;
$uri = 'https://chocolatey.org/install.ps1';
iex ((New-Object System.Net.WebClient).DownloadString("$uri"));
refreshenv;
$uri = 'https://raw.githubusercontent.com/hafah/windows10/master/install.ps1';
iex ((New-Object System.Net.WebClient).DownloadString("$uri"));
Import-Module BitsTransfer;
$uri = 'https://raw.githubusercontent.com/hafah/windows10/master/capstoctrl.reg';
Start-BitsTransfer -Source $uri;
regedit -s ./capstoctrl.reg;
sudo apt-add-repository -y ppa:rael-gc/rvm
sudo apt-get -y update
sudo apt-get -y upgrade
sudo apt-get -y install build-essential composer curl dos2unix tree tmux wget zip vagrant fish-common nodejs silversearcher-ag
sudo apt-get -y install git golang-go golang-golang-x-tools html2text python3 php php-curl php-dom php-mbstring python-minimal python-software-properties
sudo apt-get -y install p7zip-full vagrant virtualbox dkms zip software-properties-common rvm exuberant-ctags fdclone
source /etc/profile.d/rvm.sh
rvm install 2.3.1
sudo gem install tmuxodoro
sudo gem install tmuxinator
sudo apt-get -y install php php-pear
sudo apt-get -y install php7.0-dev
pecl install xdebug
export VAGRANT_WSL_ENABLE_WINDOWS_ACCESS="1"
sudo apt-get purge virtualbox
sudo apt-get remove virtualbox-dkms
sudo apt purge -y vagrant
cd /
wget https://releases.hashicorp.com/vagrant/2.1.2/vagrant_2.1.2_x86_64.deb
dpkg -i vagrant_2.1.2_x86_64.deb
rm vagrant_2.1.2_x86_64.deb
choco list -lo
choco upgrade all
choco uninstall [packagename]
I have to install desktop.github manually since it never installs through chocolatey.