iwctl device list station wlan0 scan station wlan0 get-networks station wlan0 connect WIFI exit
ping www.bilibili.com timedatectl set-ntp true
lsblk parted /dev/nvme0n1 (parted)mktable New disk label type? gpt quit
cfdisk /dev/nvme0n1 # thenset partition and its type # set 1G EFI system # set 4G swap # set [the rest space] linux root x86-64 # quit fdisk -l # linux root x86-64 mkfs.ext4 /dev/nvme0n1p3 # swap mkswap /dev/nvme0n1p2 # EFI system mkfs.fat -F 32 /dev/nvme0n1p1 # keep linux root x86-64 first mount /dev/nvme0n1p3 /mnt mkdir /mnt/efi mount /dev/nvme0n1p1 /mnt/efi swapon /dev/nvme0n1p2
vim /etc/pacman.d/mirrorlist # Put in the first line Server = https://mirrors.tuna.tsinghua.edu.cn/archlinux/$repo/os/$arch
pacstrap /mnt base base-devel linux linux-headers linux-firmware pacstrap /mnt dhcpcd iwd vim bash-completion
useradd -m -G wheel -s /bin/bash arch passwd arch # still in CLI EDITOR=vim visudo # uncomment %wheel ALL=(ALL:ALL) ALL
vim /etc/pacman.conf # unmount [multilib] section # add these [archlinuxcn] Server = https://mirrors.ustc.edu.cn/archlinuxcn/$arch Server = https://mirrors.tuna.tsinghua.edu.cn/archlinuxcn/$arch Server = https://mirrors.hit.edu.cn/archlinuxcn/$arch Server = https://repo.huaweicloud.com/archlinuxcn/$arch
pacman -Syyu # learn from https://medium.com/@mynameised/using-keyd-in-hyprland-to-rebind-your-right-alt-key-to-escape-linux-782086c81c75 sudo paru -S keyd sudo vim /etc/keyd/default.conf [ids] * [main] # hold is control, tap is esc capslock = overload(control, esc)
vim ~/.config/hypr/hyprland.conf # add these exec-once = sudo keyd