The installation method of wsl is suitable for Xiaobai, you can understand if you look at it carefully

Open the PowerShell terminal as an administrator and
run the following command:
$ Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
follow the prompts to restart the computer
Insert picture description here
and then go to https://github.com/yuk7/ArchWSL to download
Insert picture description here
Insert picture description here
the installation certificate For the appx version of arch.
You have installed the zip version.
There is no need to install twice,
only the zip is needed.

Insert picture description here
Anyway, according to my change,
save is ctrl + x and press enter

Arch.exe//This is the display after startup
[root@PC-NAME user]# passwd //This is the username and password after entering the name

Arch.exe
[root@PC-NAME]# EDITOR=nano visudo
%wheel ALL=(ALL) ALL
(setup sudoers file.)

[root@PC-NAME]# useradd -m -G wheel -s /bin/bash {username}
(add user)

[root@PC-NAME user]# passwd {username} //{} Replace with your username, remember not to type {}
(set default user password)

[root@PC-NAME user]# exit

Arch.exe config --default-user {username}
(setting to default user)
is now root user, no need to add sudo
Arch.exe
[user@PC-NAME]$ sudo pacman-key --init

[root@PC-NAME]$ sudo pacman-key --populate

It's installed

The following is the change source https://mirrors.tuna.tsinghua.edu.cn/help/archlinux/

Insert picture description here
Open is nano /etc/pacman.d/mirrorlist
Insert picture description here

Insert picture description here
Remember to go##

Then you can sudo pacman -Syy

The percentage of this tutorial can be understood. If you don’t understand it, it only means that you didn’t read
it carefully.

Guess you like

Origin blog.csdn.net/qq_44948696/article/details/109062364