X1 Extreme Gen 3 - Migrating to Wayland

I got a new laptop, so this felt like the right time to migrate to Wayland.

Delta

whatbeforeafter
hardware
laptopAsus UX501VLenovo X1 Extreme Gen 3
CPUi7-6700HQi7-10750H
GPUGTX 960MGTX 1650
RAM16GB64GB
OS
bootloaderGrubEFISTUB
OSWindows + Arch dualbootWindows + Arch dualboot
networkingnetctlsystemd-networkd
dns/dhcpdhcpcdsystemd-resolved
wifiwpa_supplicantiwd
Wayland
display/login manager--
display serverXWayland
window manageri3Sway
bari3blockswaybar
backlightxbacklightlight
night moderedshiftgammastep
clipboard-wl-clipboard, clipman
program launcherrofirofi [wayland]
password finderrofi-passrofi-pass-git
key remappingsetxkbmap, xcape, xmodmapinterception-tools
Tools
terminal emulatorurxvtfoot
shellzshfish
shell highlightingzsh-syntax-highlight-
environment variables.zshrcenvironment.d
text editorvimemacs doom
aur helperpackeryay
directory usagedudust
password managerpasspass
search toolag [silver searcher]ag + ripgrep + fd
file browserterminalterminal + ranger
calculatorqalcqalc, rofi-calc
notification deamondunstmako
image viewerfehfeh + sxiv
music-spotifyd + spotify-tui + waybar custom/media
screenshotteiler+scrotgrimshot (from sway) + custom upload wrapper
wallpaperfehsway
messengerslack, signal-desktopslack, signal-desktop [wayland]
system monitorhtophtop
remote shellsshssh
browserchromiumchromium
pdf viewerzathurazathura
vpn-openconnect

see also the i3 -> sway migration guide.

:CUSTOM_ID: hardware

BIOS

I made the following BIOS changes for the X1 Extreme Gen 3 (X1E3):

windows

In order to keep the existing Windows installation with dual boot, we need to finish its installation and shrink the partition.

  • Use airplane mode (F8) to skip signing in to a microsoft account.
  • Install chromium and delete Edge.
  • Disable hibernation.
  • Disable virtual memory (i.e. swap) to save some disk space.
  • Shrink the C volume in device memory.
  • Update drivers/bios using lenovo vantage.

Install Arch

efistub

https://wiki.archlinux.org/title/EFISTUB

  • Mount existing efi partition to /boot
  • May have to (re)install the kernel to make sure vmlinuz-linux is written to the mounted efi partition at /boot
  • install intel-ucode
  • https://wiki.archlinux.org/title/Microcode
  • run efibootmgr command as explained, but add in the microcode part

Network

  • systemd-networkd
  • systemd-resolved
  • iwd for adding/changing wireless connections using iwctl.

Bluetooth

  • start blueman-applet from sway
  • enable bluetooth.service

Spotify

Audio: pipewire

I have been using pipewire as my audio backend, and so far it has been working without problems. Installing it together with pipewire-alsa, pipewire-jack, pipewire-pulse and pavucontrol gives everything I need.

Wayland

See this post.

SWAY

See this post.

Environment variables: environment.d

I’m using environment.d to set my environment variables. This post has the details.

1
2
3
4
5
6
7
8
9
# Color schemes
GTK_THEME=Adwaita:dark

# Editor
EDITOR="emacsclient -c"
VISUAL="emacsclient -c"

# Make weeks start on Monday
LC_TIME="en_GB.UTF-8"

Homedir cleanup

Have a look at XDG Base directory to keep your homedir tidy.

Emacs

See this post.