refactor(content): artix install guide synatx improvements
All checks were successful
build dist / build-dist (push) Successful in 38s

This commit is contained in:
z0x 2025-04-27 11:18:33 -04:00
parent a933186b87
commit 7d7ae30940

View file

@ -37,7 +37,7 @@ Use [Rufus](https://rufus.ie/en)
```shell ```shell
sudo dd bs=4M if=~/Downloads/artix-base-openrc-*-x86_64.iso of=/dev/sdb1 conv=fsync oflag=direct status=progress doas dd bs=4M if=~/Downloads/artix-base-openrc-*-x86_64.iso of=/dev/sdb1 conv=fsync oflag=direct status=progress
``` ```
--- ---
@ -281,10 +281,10 @@ rc-update add NetworkManager
rc-update add iwd rc-update add iwd
``` ```
``` ```diff
<!-- /etc/NetworkManager/conf.d/wifi_backend.conf --> <!-- /etc/NetworkManager/conf.d/wifi_backend.conf -->
[device] +[device]
wifi.backend=iwd +wifi.backend=iwd
``` ```
### MAC randomization ### MAC randomization
@ -292,14 +292,14 @@ wifi.backend=iwd
> [!info] > [!info]
>MAC randomization can be used for increased privacy by not disclosing your real MAC address to the WiFi network. >MAC randomization can be used for increased privacy by not disclosing your real MAC address to the WiFi network.
```ini ```diff
<!-- /etc/NetworkManager/conf.d/00-macrandomize.conf --> <!-- /etc/NetworkManager/conf.d/00-macrandomize.conf -->
[device-mac-randomization] +[device-mac-randomization]
wifi.scan-rand-mac-address=yes +wifi.scan-rand-mac-address=yes
[connection-mac-randomization] +[connection-mac-randomization]
ethernet.cloned-mac-address=random +ethernet.cloned-mac-address=random
wifi.cloned-mac-address=random +wifi.cloned-mac-address=random
``` ```
## Localization ## Localization
@ -357,9 +357,9 @@ echo 'artix' > /etc/hostname
```diff ```diff
<!-- /etc/conf.d/hostname --> <!-- /etc/conf.d/hostname -->
# Hostname fallback if /etc/hostname does not exist # Use fallback hostname if /etc/hostname doesn't exist
- hostname="localhost" -hostname="localhost"
+ hostname="odin" +hostname="artix"
``` ```
```ini ```ini
@ -378,10 +378,9 @@ echo 'artix' > /etc/hostname
In the `HOOKS` array, add `encrypt` between `block` and `filesystems` In the `HOOKS` array, add `encrypt` between `block` and `filesystems`
```diff ```diff ins="encrypt" showLineNumbers=false
<!-- /etc/mkinitcpio.conf --> <!-- /etc/mkinitcpio.conf -->
- HOOKS=(... block filesystems ...) HOOKS=(... block encrypt filesystems ...)
+ HOOKS=(... block encrypt filesystems ...)
``` ```
Generate initramfs images Generate initramfs images
@ -422,8 +421,8 @@ chmod -c 0400 /etc/doas.conf
2. Add the following 2. Add the following
```diff ```diff
<!-- /etc/doas.conf --> <!-- /etc/doas.conf -->
+ permit artix as root +permit artix as root
+ permit nopass artix as root cmd pacman +permit nopass artix as root cmd pacman
``` ```
--- ---
@ -479,11 +478,10 @@ blkid -s UUID -o value /dev/nvme0n1p2
> GRUB_ENABLE_CRYPTODISK=y > GRUB_ENABLE_CRYPTODISK=y
> ``` > ```
```diff ```diff showLineNumbers=false del="#" ins="cryptdevice=UUID=xxxx:root root=/dev/mapper/root"
<!-- /etc/default/grub --> <!-- /etc/default/grub -->
+ GRUB_CMDLINE_LINUX_DEFAULT="cryptdevice=UUID=xxxx:root root=/dev/mapper/root" ... GRUB_CMDLINE_LINUX_DEFAULT="cryptdevice=UUID=xxxx:root root=/dev/mapper/root"
+ GRUB_ENABLE_CRYPTODISK=y #GRUB_ENABLE_CRYPTODISK=y
- #GRUB_ENABLE_CRYPTODISK=y
``` ```
6. Generate the config file 6. Generate the config file
@ -525,35 +523,24 @@ doas sh -c "curl https://archlinux.org/mirrorlist/all -o /etc/pacman.d/mirrorlis
2. Activate Arch mirrors 2. Activate Arch mirrors
> [!note] ```diff del="#"
> This file requires root permissions to edit
```diff
<!-- /etc/pacman.d/mirrorlist-arch --> <!-- /etc/pacman.d/mirrorlist-arch -->
## Worldwide #Server = https://geo.mirror.pkgbuild.com/$repo/os/$arch
- #Server = https://geo.mirror.pkgbuild.com/$repo/os/$arch #Server = https://ftpmirror.infania.net/mirror/archlinux/$repo/os/$arch
- #Server = https://ftpmirror.infania.net/mirror/archlinux/$repo/os/$arch #Server = http://mirror.rackspace.com/archlinux/$repo/os/$arch
- #Server = http://mirror.rackspace.com/archlinux/$repo/os/$arch #Server = https://mirror.rackspace.com/archlinux/$repo/os/$arch
- #Server = https://mirror.rackspace.com/archlinux/$repo/os/$arch
+ Server = https://geo.mirror.pkgbuild.com/$repo/os/$arch
+ Server = https://ftpmirror.infania.net/mirror/archlinux/$repo/os/$arch
+ Server = http://mirror.rackspace.com/archlinux/$repo/os/$arch
+ Server = https://mirror.rackspace.com/archlinux/$repo/os/$arch
``` ```
3. Edit the pacman config file 3. Edit the pacman config file
> [!note] ```diff
> This file requires root permissions to edit
```ini
<!-- /etc/pacman.conf --> <!-- /etc/pacman.conf -->
##Arch +##Arch
[extra] +[extra]
Include = /etc/pacman.d/mirrorlist-arch +Include = /etc/pacman.d/mirrorlist-arch
##[multilib] +##[multilib]
##Include = /etc/pacman.d/mirrorlist-arch +##Include = /etc/pacman.d/mirrorlist-arch
``` ```
#### Sort for fastest mirrors #### Sort for fastest mirrors
@ -566,15 +553,25 @@ doas sh -c "rankmirrors -v -n 5 /etc/pacman.d/mirrorlist.bak > /etc/pacman.d/mir
``` ```
### AUR ### AUR
#### Add Chaotic-AUR
```sh
doas pacman-key --recv-key 3056513887B78AEB --keyserver keyserver.ubuntu.com
doas pacman-key --lsign-key 3056513887B78AEB
doas pacman -U 'https://cdn-mirror.chaotic.cx/chaotic-aur/chaotic-keyring.pkg.tar.zst'
doas pacman -U 'https://cdn-mirror.chaotic.cx/chaotic-aur/chaotic-mirrorlist.pkg.tar.zst'
```
```diff showLineNumbers=false
<!-- /etc/pacman.conf -->
+[chaotic-aur]
+Include = /etc/pacman.d/chaotic-mirrorlist
```
#### Install paru #### Install paru
```sh ```sh
doas pacman -S --needed base-devel doas pacman -Syu
git clone https://aur.archlinux.org/paru.git doas pacman -S paru
cd paru
makepkg -si
cd ..
rm -rf paru
``` ```
#### Replace sudo with doas #### Replace sudo with doas
@ -608,6 +605,7 @@ echo '/swapfile none swap sw 0 0' | doas tee -a /etc/fstab
### Auto-mount an external LUKS encrypted drive ### Auto-mount an external LUKS encrypted drive
```sh ```sh
doas pacman -S cryptsetup-openrc fdisk
doas fdisk /dev/sdb doas fdisk /dev/sdb
>g, n, w >g, n, w
@ -621,14 +619,17 @@ doas dd if=/dev/urandom of=/root/keyfile_hdd1 bs=512 count=4
doas chmod 0400 /root/keyfile_hdd1 doas chmod 0400 /root/keyfile_hdd1
doas cryptsetup luksAddKey /dev/sdb1 /root/keyfile_hdd1 doas cryptsetup luksAddKey /dev/sdb1 /root/keyfile_hdd1
UUID=$(doas blkid -s UUID -o value /dev/sdb1) UUID=$(doas blkid -s UUID -o value /dev/sdb1)
```
doas sh -c "cat << EOF >> /etc/conf.d/dmcrypt ```diff showLineNumbers=false
target=hdd1 <!-- /etc/conf.d/dmcrypt -->
source=UUID='$UUID' +target=hdd1
key=/root/keyfile_hdd1 +source=UUID='$UUID'
wait=2 +key=/root/keyfile_hdd1
EOF" +wait=2
```
```sh
doas rc-update add dmcrypt boot doas rc-update add dmcrypt boot
doas reboot doas reboot
``` ```