Shhware

English · Russian

Install

Supported distributions

DistroInitNotes
Artix Linuxs6seatd (instead of elogind)
Void Linuxrunitmusl (the C library, instead of glibc)

Coming soon

  • Gentoo
  • CRUX
  • KISS

Before you start

  • A user in the wheel group. Run everything as that user, not root: install.sh stops when run as root.
  • Internet.

Artix installation

A fresh base install with the s6* (important) init and seatd* (important) (pick seatd-s6).

How to install Artix (Artix wiki)

  1. Install git:
    sudo pacman -S git
  2. Clone the repo:
    git clone https://github.com/kiran-why/Shh-dotfiles.git ~/Shh-dotfiles
  3. Install the dotfiles:
    cd ~/Shh-dotfiles
    sh install.sh
    The install log: ~/.local/state/shh/install.log (the last run only, from the shh config menu on).
  4. Remove the repo (optional), only in copy mode (the default: the configs are copies, not links to the repo)* (important) in shh config; shh update downloads it again:
    cd ~ && rm -rf ~/Shh-dotfiles
  5. Reboot and log in on tty1: sway starts by itself.

Void installation

A fresh base install with musl (the C library, instead of glibc)* (important): the setup is tested on musl only. seatd comes with the packages (no elogind).

How to install Void (Void handbook)

  1. Update xbps* (important), a fresh system must do it first:
    sudo xbps-install -Su xbps
  2. Install git:
    sudo xbps-install -S git
  3. Clone the repo:
    git clone https://github.com/kiran-why/Shh-dotfiles.git ~/Shh-dotfiles
  4. Install the dotfiles:
    cd ~/Shh-dotfiles
    sh install.sh
    The install log: ~/.local/state/shh/install.log (the last run only, from the shh config menu on).
  5. Remove the repo (optional), only in copy mode (the default: the configs are copies, not links to the repo)* (important) in shh config; shh update downloads it again:
    cd ~ && rm -rf ~/Shh-dotfiles
  6. Reboot and log in on tty1: sway starts by itself.

Additional info

Checking package names

cd ~/Shh-dotfiles
sh install.sh --check

Checks that every package in the lists exists in the repositories, installs nothing. It checks all lists of the distro, not only this machine's: system/artix/packages, system/void/packages. Whether the packages are installed: shh doctor.

How the script works

install.sh is the same on every distro. It loads into itself (., same process) lib/lib.sh and the distro's own steps, system/DISTRO/distro.sh.

It runs as separate processes:

  • scripts/hardware: the VM type or the graphics cards;
  • shh config: what to install, on the first run only;
  • lib/link.sh (about it): puts the configs into your home folder;
  • scripts/vpn setup: the sing-box service, unless sing-box is turned off in shh config.

It reads these lists (DISTRO = artix or void):

  • system/DISTRO/packages/common.csv: packages for every machine;
  • system/DISTRO/packages/CARD.csv: the graphics driver of each card found (Artix: amd, intel, nvidia, nvidia-580xx; Void: amd, intel);
  • system/DISTRO/services.txt: services started at boot;
  • components/DISTRO_components.txt: parts you can turn off in shh config.

It changes these system files. A file it writes whole is renamed to FILE.bak-DATE first, if it had other content; to the others it only adds lines:

  • /etc/iwd/main.conf: iwd gets IP addresses itself, DNS goes through resolvconf;
  • /etc/dhcpcd.conf: adds denyinterfaces wl*, dhcpcd only for wired network, wifi is iwd's;
  • /etc/resolvconf.conf: the DNS servers from shh config;
  • /etc/modprobe.d/nvidia-modeset.conf: NVIDIA driver only, kernel modesetting for sway;
  • /etc/modprobe.d/nobeep.conf: the PC speaker off (shh config: nobeep);
  • /etc/udev/rules.d/90-shh-backlight.rules: the group video may change the screen brightness;
  • /etc/sudoers.d/shh-power: poweroff, reboot and sleep without a password;
  • /etc/sudoers.d/dotfiles-temp: passwordless sudo while the script runs, removed when it ends;
  • sing-box on: /etc/sing-box/ and its service;
  • Artix: /etc/pam.d/system-login: adds pam_rundir (XDG_RUNTIME_DIR at login, sway needs it);
  • Artix: /etc/pacman.conf: the Arch repos ([extra]), and with the pacman setting in shh config colors and parallel downloads; /etc/makepkg.conf: AUR builds on all CPU cores;
  • Void: /etc/alsa/conf.d/: ALSA programs play through pipewire.

It also sets zsh as your login shell and adds you to the groups for seatd, sound and video.

Steps

  1. check_system: not root, a supported distro, sudo, the lists, internet;
  2. choose_parts: the shh config menu on the first run;
  3. start_log: a copy of the output in ~/.local/state/shh/install.log (last run only);
  4. enable_nopasswd: temporary passwordless sudo, so AUR builds don't ask again and again;
  5. distro_prepare: Artix: pacman settings, the Arch repos, the AUR helper; Void: updates xbps and the system;
  6. vmware_clipboard: in VMware only, the clipboard between the host and the VM (Artix; not packaged for Void). Script: scripts/vmware-clipboard → ~/.local/bin/vmware-clipboard, started with sway;
  7. install_packages: the lists, minus the parts turned off;
  8. configure_gpu: the settings the graphics driver needs;
  9. configure_network: iwd, dhcpcd, DNS;
  10. enable_services: services.txt, the sing-box service, the groups; turns off the unused consoles: tty3–tty6, on Artix also ttyS;
  11. configure_system: login shell, XDG_RUNTIME_DIR, PC speaker, brightness;
  12. configure_power: poweroff, reboot, sleep without a password;
  13. link_dotfiles: lib/link.sh, copy or link mode from shh config;
  14. leftovers: packages of parts turned off, removed only if you answer y.