NOTE: This requires Windows 11 to work fully. If you're on Windows 10, you won't have working systemd. If you're on an older version of WSL, you should try https://github.com/yuk7/ArchWSL or https://github.com/sileshn/ArchWSL2 instead.
curl -L https://geo.mirror.pkgbuild.com/iso/latest/archlinux-bootstrap-x86_64.tar.zst -o base.tar.gz
sudo bsdtar xzpf base.tar.gz
bsdtar czf arch.tar.gz -C root.x86_64 .
or
curl -sL https://geo.mirror.pkgbuild.com/iso/latest/archlinux-bootstrap-x86_64.tar.gz | bsdtar czf arch.tar.gz --strip-components=1 @-
Copy arch.tar.gz to somewhere on your Windows machine.
wsl --import Arch %USERPROFILE%\Arch arch.tar.gz --version 2
wsl -d Arch
Fill in the commands according to your own needs, particularly the mirror countries for reflector, the installed pacman packages, the locale, as well as the name for the new default user.
pacman-key --init
pacman-key --populate
sed -i 's/^#Server/Server/' /etc/pacman.d/mirrorlist
pacman -Syy archlinux-keyring rsync reflector
reflector -c de,fr, -l 20 -f 10 -p https,rsync --save /etc/pacman.d/mirrorlist
pacman -Suu pacman-contrib sudo neovim zsh grml-zsh-config
sed -i 's/^#en_US.UTF-8/en_US.UTF-8/' /etc/locale.gen
locale-gen
echo 'LANG=en_US.UTF-8' > /etc/locale.conf
# Enable wheel group
EDITOR=nvim visudo
useradd -mG wheel -s /usr/bin/zsh lambda
passwd lambda
cat >/etc/wsl.conf <<EOF
[boot]
systemd = true
[user]
default = lambda
EOF
exit
wsl --shutdown
timeout /t 8 /nobreak
wsl -d Arch