- check wsl box in windows features settings
- powershell:
wsl --set-default-version 2 - download ubuntu here: https://docs.microsoft.com/de-de/windows/wsl/install-manual
- powershell:
Add-AppxPackage .\app_name.appx(choose ubuntu.appx file) - powershell:
wsl -l -v=>wsl --setdefault <DistributionName> - if docker does not work just exit terminal and reenter ubuntu with "wsl"
- solve dns internet problem: microsoft/WSL#5256 (comment)
Steps that have worked for me: Boot your distro. cd ~/../../etc Create wsl.conf, however you see fit. sudo vim wsl.conf, sudo touch wsl.conf and edit it later, whatever. Add these lines to wsl.conf: [network] generateResolvConf=false exit or in Windows cmd wsl --terminate [YourDistroName] Boot your distro. At this point, thanks to wsl.conf, run/resolvconf should no longer exist and will never be created again. cd ~/../../etc sudo rm resolv.conf - this deletes the existing symlink file. Create a new resolv.conf, however you see fit. sudo vim resolv.conf, sudo touch resolv.conf and edit it later, whatever. Add this line to resolv.conf: nameserver 8.8.8.8 replace 8.8.8.8 with your preferred functional nameserver. exit or in Windows cmd wsl --terminate [YourDistroName] wsl --shutdown just to be sure that you've definitely killed everything. Boot your distro. Confirm that your resolv.conf changes are still in effect, or just ping a domain name and cry tears of joy after struggling to get this working for far too fucking long
- https://docs.microsoft.com/en-us/windows/wsl/tutorials/wsl-git
- git should be preinsalled on linux wsl
- configure git config in wsl
git config --global user.name "Your Name" git config --global user.email "[email protected]"
- Use Git Credential Manager for authentication: https://docs.microsoft.com/en-us/windows/wsl/tutorials/wsl-git#git-credential-manager-setup
- Should be installed with git for windows: https://git-scm.com/download/win
- if not install from here:
- To set up GCM Core for use with a WSL distribution, open your distribution and enter this command:
# old wrong # git config --global credential.helper "/mnt/c/Program\ Files/Git/mingw64/libexec/git-core/git-credential-manager-core.exe" # new changed location: https://github.com/microsoft/WSL/issues/8395#issuecomment-1121629434 git config --global credential.helper "/mnt/c/Program\ Files/Git/mingw64/bin/git-credential-manager-core.exe"