Fix/install issues keyserver fallback, SDDM autologin user, claude-code conflict, nvidia package checks - #38
Closed
gabotachak wants to merge 2 commits into
Closed
Conversation
…rm from chwd Remove open-driver packages one by one after verifying they are installed, avoiding pacman errors on clean systems. Remove --noconfirm from chwd -r since chwd does not accept that flag and would exit non-zero. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…laude-code Three crash-on-rerun fixes: - Retry Omarchy signing key import across multiple keyservers instead of failing immediately when one keyserver is unreachable. - Patch SDDM autologin.conf to use OMARCHY_USER_NAME instead of $USER; the script runs as root so $USER resolves to root, locking users out. - Remove existing claude-code package or binary before install.sh runs; pacman aborts if /usr/bin/claude already exists from a prior CachyOS install. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
gabotachak
force-pushed
the
fix/install-issues
branch
from
May 13, 2026 05:28
1a382ad to
62539d0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix installer crashes: keyserver fallback, SDDM autologin user, claude-code conflict, nvidia package checks
Background
These fixes come from actually running the installer end-to-end on a fresh CachyOS system. Five bugs caused hard crashes or silent misconfigurations that only surface during a real install — none of them are visible in a dry-run or code review. They are documented here in the order you hit them.
One lesson learned the hard way: attempting this install from a CachyOS minimal/no-GUI system is not worth it. The installer assumes a running Wayland session (for
hyprctl,wl-paste, SDDM already configured, etc.). Start from CachyOS with the Hyprland desktop environment pre-installed — that is the only baseline that has been tested and where everything works as expected.Bugs Fixed
1.
pacman-key --recv-keysfails silently when keyserver is unreachableScript:
install-omarchy-on-cachyos.shWhat happened: The default keyserver (
keys.gnupg.net) is frequently unreachable or rate-limited. The singlepacman-key --recv-keyscall would fail with no retry, leaving the Omarchy signing key unimported. Every subsequentpacmanoperation against the[omarchy]repository would then fail with a signature verification error, halting the install.Fix: The key import now loops over three keyservers (
keyserver.ubuntu.comover HKPS,keys.openpgp.org, andkeyserver.ubuntu.comover plain HKP port 80 as a last resort). It breaks on the first success. If all three fail, the script exits with a clear error instead of continuing into a broken state.2. SDDM autologin configured as
User=rootScript:
install-omarchy-on-cachyos.shWhat happened: Omarchy's
install/login/sddm.shwrites/etc/sddm.conf.d/autologin.confwithUser=$USER. Because the installer runs as root (viasudo),$USERexpands torootat the time the sed patch is applied. The result: SDDM autologin tries to start a Hyprland session as root, which Hyprland refuses. The machine boots to a broken login loop.Fix: Before copying the Omarchy tree, the script patches
install/login/sddm.shto replace$USERwith the value of$OMARCHY_USER_NAME(already set earlier in the script to the actual non-root user). This happens at patch time, beforeinstall.shruns, so the written config contains the correct username.3.
pacmanaborts with file conflict on/usr/bin/claudeScript:
install-omarchy-on-cachyos.shWhat happened: CachyOS ships
claude-codein its repositories. If the user installed it (or it was pulled in as a dependency),/usr/bin/claudealready exists on the system. When Omarchy'sinstall.shruns and tries to install its ownclaude-codepackage,pacmandetects a file conflict and aborts. This happens near the end of the install, after all other packages are already installed, making it both surprising and disruptive.Fix: Just before running
install.sh, the script checks for and removes any existingclaude-codeinstallation. It handles both the case where the full package is installed (usespacman -Rddto skip dependency checks) and the case where only the binary exists as a stray file.4.
nvidia.shcrashes when open-driver packages are not installedScript:
nvidia.shWhat happened: The original removal command listed all four conflicting packages in a single
pacman -Rddcall with2>/dev/null || true. If any of the packages were not installed (e.g., on a fresh minimal CachyOS without the Hyprland desktop),pacmanexits non-zero for the whole batch. The|| truemasked this — but on some system configurations,set -eor wrapper logic caused the script to abort prematurely.Fix: Each package is checked individually with
pacman -Qbefore attempting removal. This is explicit, avoids suppressing real errors with a blanket|| true, and produces clear per-package output for debugging.5.
chwd -rrejects--noconfirmflag and exits non-zeroScript:
nvidia.shWhat happened: The call to remove the old NVIDIA profile passed
--noconfirmtochwd. Unlikepacman,chwddoes not recognize this flag and exits with an error. Since this step ran before the profile install, the script would abort before the proprietary 580xx driver was ever installed, leaving the system in an inconsistent state with no working NVIDIA driver.Fix: Remove the invalid flag.
chwd -ris interactive but only when there is something to confirm — on a system where the profile is already absent (idempotent re-run), it exits cleanly. The|| trueis kept to handle the absent-profile case.Recommended Installation Baseline
Install CachyOS with the Hyprland desktop environment selected during setup. This gives you:
hyprctlavailable for monitor detection in post-install scriptsInstalling from a minimal/no-GUI CachyOS system requires manually resolving session, display manager, and shell assumptions baked into the Omarchy installer. It is possible but significantly more painful and has not been tested as a supported path.