Basic
在开始前,确保能正确访问服务器,提前配置好clash-verge (可选) 避免出现不必要的问题 快速部署:crowforkotlin github arch dotfiles
archlinux 1 sudo nvim /etc/pacman.conf
添加到最后一行
1 2 [archlinuxcn] Server = https://repo.archlinuxcn.org/$arch
1 2 sudo pacman -Sy sudo pacman -S archlinuxcn-keyring
pacman 1 sudo pacman -Syu nvm fvm jenv pyenv android-tools net-tools tree bat fastfetch curl neovim vim ghostty fcitx5-im fcitx5-rime ttf-jetbrains-mono-nerd wl-clipboard cliphist tmux ripgrep btop zram-generator p7zip reflector jq imv mpv ffmpegthumbnailer gst-plugins-base gst-plugins-good gst-libav ddcutil obs-studio inter-font ttf-fira-code zenity baobab gdu zenity dnsmasq clang camke os-prober grub efibootmgr dconf-editor wine fsearch --needed base-devel --noconfirm
obs for intel
1 sudo pacman -S onevpl-intel-gpu
yay 1 mkdir -p ~/develop/github/ && mkdir -p ~/develop/work/ && mkdir -p ~/deveop/agents/ && git clone https://aur.archlinux.org/yay.git ~/develop/github/yay/ && cd ~/develop/github/yay/ && makepkg -si && rm -rf ~/develop/github/yay/
1 yay -Syu rime-ice-git ttf-jetbrains-maple-mono-nf-xx-xx visual-studio-code-bin aliyun-adrive-bin clash-verge-rev-bin linuxqq-clipsync-git satty paru android-studio ab-download-manager-bin wps-office-cn --noconfirm
paru 1 paru -S ttf-maplemono-nf-cn-unhinted wf-recorder
fonts | ghostty | gtk | cursor 1 nvim ~/.config/fontconfig/fonts.conf
1 2 3 4 5 6 7 8 9 10 11 12 <?xml version="1.0" ?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd" > <fontconfig > <alias > <family > monospace</family > <prefer > <family > Maple Mono NF CN</family > <family > Maple Mono NF</family > <family > JetBrainsMono Nerd Font</family > </prefer > </alias > </fontconfig >
1 2 3 4 5 6 mkdir -p ~/.local/share/fonts/truetype/K2D && \ curl -s "https://fonts.google.com/download/list?family=K2D" | \ sed '1s/^)]}'\''//' | \ jq -r '.manifest.fileRefs[] | select(.url != null and (.filename | endswith(".ttf"))) | "\(.url)\t\(.filename)"' | \ xargs -r -n 2 -P 8 sh -c 'curl -L -# -o "$HOME/.local/share/fonts/truetype/K2D/$2" "$1"' _ && \ fc-cache -fv
1 gsettings set org.gnome.desktop.interface font-name 'K2D:weight=semibold 11'
1 2 3 fc-cache -fv fc-match "Maple Mono NF CN" fc-list | grep -i "jetbrains\|maple|K2D"
1 mkdir -p ~/.local/share/icons && for v in Dark Light Black; do curl -L "https://github.com/ful1e5/BreezeX_Cursor/releases/download/v2.0.1/BreezeX-${v}.tar.xz" | tar -xJ -C ~/.local/share/icons/; done
memory(zram 8g | swap 10g) 1 2 3 4 5 6 7 8 9 10 11 12 13 echo -e "[zram0]\nzram-size = min(ram, 8192)\ncompression-algorithm = zstd" | sudo tee /etc/systemd/zram-generator.conf sudo systemctl daemon-reload sudo systemctl restart systemd-zram-setup@zram0.service sudo dd if=/dev/zero of=/swapfile bs=1M count=10240 status=progress sudo swapoff /swapfile sudo rm /swapfile sudo dd if=/dev/zero of=/swapfile bs=1M count=10240 status=progress sudo chmod 600 /swapfile sudo mkswap /swapfile sudo swapon /swapfile echo '/swapfile none swap defaults 0 0' | sudo tee -a /etc/fstab zramctl && swapon --show && free -h
Brigness 1 2 3 4 5 6 sudo modprobe i2c_dev echo "i2c_dev" | sudo tee /etc/modules-load.d/i2c_dev.conf sudo pacman -S ddcutil sudo usermod -aG i2c $USER ddcutil detect systemctl --user restart dms.service
Niri
直接git clone省去以下流程
1 git clone <https://github.com/crowforkotlin/crowforkotlin.config.niri.git> ~/.config/niri/
1 2 3 curl -L https://github.com/crowforkotlin/BreezeX_Cursor/releases/download/1.0/BreezeX-Dark.tar.xz -o /tmp/BreezeX-Dark.tar.xz && tar -xf /tmp/BreezeX-Dark.tar.xz -C /tmp && mkdir -p ~/.local/share/icons && cp -r /tmp/BreezeX-Dark ~/.local/share/icons/ && rm /tmp/BreezeX-Dark.tar.xz && rm -rf /tmp/BreezeX-Dark ```shell nvim ~/.config/niri/config.kdl
1 include "dms/custom/index.kdl"
1 nvim ~/.config/niri/dms/custom/index.kdl
1 2 3 4 5 include "config.kdl" include "cursor.kdl" include "layout.kdl" include "binds.kdl" include "windowrules.kdl"
1 ~/.config/niri/dms/custom/cursor.dms
1 2 3 4 5 cursor { xcursor-theme "BreezeX-Dark" xcursor-size 36 hide-after-inactive-ms 15000 }
1 nvim ~/.config/niri/dms/custom/binds.kdl
1 2 3 4 5 6 7 8 9 10 11 binds { Mod+Alt+A { screenshot show-pointer=false; } Mod+Alt+S { screenshot-screen show-pointer=false; } Mod+Alt+D { spawn-sh "wl-paste | satty -f -"; } Mod+G repeat=false { toggle-overview; } Mod+A { consume-or-expel-window-left; } Mod+D { consume-or-expel-window-right; } Mod+Shift+Q { spawn "sh" "-c" "pid=$(niri msg -j focused-window | jq '.pid'); [ -n \"$pid\" ] && pkill -P $pid 2>/dev/null; kill $pid 2>/dev/null"; } Mod+T hotkey-overlay-title="Open Terminal" { spawn "ghostty"; } Mod+B hotkey-overlay-title="Open Chrome" { spawn "google-chrome-stable"; } }
1 nvim ~/.config/niri/dms/custom/layout.kdl
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 layout { gaps 12 border { width 2 } focus-ring { width 2 } shadow { on softness 20 spread 2 offset x=-4 y=-4 color "rgba(0, 0, 0, 0.7)" } } window-rule { geometry-corner-radius 12 clip-to-geometry true tiled-state true draw-border-with-background false } overview { workspace-shadow { on } zoom 0.5 }
1 nvim ~/.config/niri/dms/custom/windowrules.kdl
1 // .... https://github.com/crowforkotlin/crowforkotlin.config.niri/blob/main/dms/custom/windowrules.kdl
Fcitx5 1 2 3 4 git clone https://github.com/sanweiya/fcitx5-mellow-themes.git cd fcitx5-mellow-themes/ mkdir -p ~/.local/share/fcitx5/themes && cp -r ./mellow-* ~/.local/share/fcitx5/themes nvim ~/.config/fcitx5/conf/classicui.conf
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 PreferTextIcon=True ShowLayoutNameInIcon=True UseInputMethodLanguageToDisplayText=True TrayFont="Sans Bold 10" TrayOutlineColor=#000000 TrayTextColor=#ffffff Vertical Candidate List=False WheelForPaging=True Font="Maple Mono NF CN SemiBold Demi-Bold 11" MenuFont="Sans 10" TrayFont="Sans Bold 10" TrayOutlineColor=#00000001 TrayTextColor=#ffffff PreferTextIcon=True ShowLayoutNameInIcon=True UseInputMethodLanguageToDisplayText=True Theme=mellow-youlan DarkTheme=mellow-youlan-dark UseDarkTheme=False UseAccentColor=True PerScreenDPI=False ForceWaylandDPI=0 EnableFractionalScale=True
rime 1 nvim ~/.local/share/fcitx5/rime/default.custom.yaml
1 2 3 4 5 6 7 8 9 patch: schema_list: - schema: rime_ice "menu/page_size": 5 key_binder/bindings: - { accept: bracketleft , send: Page_Up , when: has_menu } - { accept: bracketright , send: Page_Down , when: has_menu } - { accept: Left , send: Up , when: has_menu } - { accept: Right , send: Down , when: has_menu }