feat(cachyos): CachyOS desktop setup + Claude install improvements#18
Conversation
- install.sh: install railguard via cargo and run railguard install - README: document railguard hook, post-test-runner hook, and updated activation steps - TODO.md: safeguard validation checklist and sandbox revisit items Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
macOS/setup.sh: ${=names} is zsh word-split syntax — bash treats it as
bad substitution. Switch shebang to bash, set -euo pipefail, and drop
the = operator (bash word-splits unquoted vars by default). Also fix
[ -s ] → [[ -s ]] in the nvm sourcing block.
agentic-ai/Claude/install.sh: railguard install (the config step) only
ran on a fresh binary install, so re-running the script never repaired
broken railguard state. Move it unconditionally after the binary check.
Also surface a clear error if cargo install railguard fails instead of
silently exiting via set -e.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- install.sh: resolve CARGO_BIN via command -v instead of hardcoding $HOME/.cargo/bin/cargo (fixes failure when cargo is installed via Homebrew) - install.sh: save/restore settings.json around railguard install so railguard's machine-specific absolute paths don't overwrite the portable ~ paths in the repo version - settings.json: restore custom hooks (validate-bash, validate-write, post-edit-shellcheck, post-test-runner) dropped by railguard install; add CLAUDE_CODE_SHELL env var; use ~ paths throughout - CLAUDE.md: commit railguard's instructions block (idempotent on re-install) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Checks symlinks, hook wiring, required binaries (jq, shellcheck, pytest), settings.json integrity, railguard binary, and runs smoke tests against each hook with known-good and known-bad payloads. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
setup.sh was hardcoded to Ubuntu (apt/snap). Make it distro-aware: - Auto-detect ubuntu/arch from /etc/os-release (+ --distro override) - Bootstrap yay via pacman, then drive repo+AUR installs through yay - Enable tailscaled on Arch; distro-aware pyenv build deps - Fix shell switch to read the real login shell via getent (handles fish -> zsh when $SHELL is an inherited interactive zsh over SSH) JSON: pyenv/nvm use the curl installers on Arch too (unified ~/.pyenv and ~/.nvm across all OSes); fix hf arch_name to python-huggingface-hub; add pre-commit + shellcheck (the repo's own dev gate). zshrc.example: add guarded pyenv/nvm init (was missing on all platforms). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…batch The pyenv step ran `eval "$(pyenv init -)"`, which detects the shell from $SHELL and emits fish/zsh syntax. Under a fish login shell that syntax fails in this bash script's eval, and set -e aborted the whole run right after pyenv installed — so nvm, the medium package batch, the shell switch, and the zshrc/ghostty config never ran. Force `pyenv init - bash`. Also make yay_install resilient: if the batch install errors (e.g. one AUR build breaks), retry packages individually so a single failure can't abort the run and skip the shell/config steps. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
CachyOS ships zlib-ng-compat (which provides zlib), so `pacman -S zlib` wants to replace it -> unresolvable conflict -> --noconfirm declines -> set -e aborts the run before pyenv installs Python. Filter the Arch build deps through `pacman -T` and only install the unsatisfied ones (e.g. tk). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Distro-aware (Ubuntu/Arch) verification script mirroring setup.sh's selection logic, so the same flags check exactly what setup.sh installs. Also checks runtime state: login shell is zsh, pyenv Python, nvm Node, antidote, zshrc/plugins/ghostty configs, and the tailscaled service. Verified on CachyOS: 52/52 with --work. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add a RELATED_SCRIPTS array + print_related_scripts() so the done message points at the repo's other installers (Claude config, SSH/GPG key scripts, verify.sh). Only scripts present on disk are shown; adding a new one is a one-line array entry. Replaces the previously hardcoded SSH/GPG lines. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
# Conflicts: # macOS/setup.sh
Mirror the RELATED_SCRIPTS discoverability block from linux-desktop/setup.sh into macOS/setup.sh so a run ends by pointing at Claude config, SSH/GPG key generation, and verify.sh — only scripts present on disk are shown. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Capture the agreed architecture for collapsing the three per-folder setup stacks into one root setup.sh + single packages.json (managers keyed by platform, shared lib/core.sh, platforms/ modules). Detailed enough to pick up in a separate PR: schema spec, old→new migration rules, phased breakdown with dry-run parity gates, and open questions. Link the phases from TODO.md. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Addresses #23 — npm minimum release age (supply-chain cooldown)Adds a 7-day Patch:
Checks: Note: npm's |
Write a user-level ~/.npmrc with min-release-age=7 during nvm/Node setup so npm refuses to install package versions younger than 7 days, mitigating token-theft attacks where a poisoned patch of a trusted package runs within seconds of install. Applied before the repo's own `npm install -g` steps. Helper is idempotent, portable, preserves existing .npmrc lines, and respects --dry-run. verify.sh confirms the setting on both platforms. Closes #23 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Enable pnpm through corepack (ships with nvm's Node) during setup and apply a 7-day supply-chain cooldown via `pnpm config set minimumReleaseAge 10080` (minutes; set explicitly so pnpm enforces it strictly — the built-in 1-day default is non-strict). Migrate the sole npm package (codeburn) to `pnpm add -g` and wire PNPM_HOME onto PATH (zshrc.example on Linux, add_to_zshrc on macOS) so globally-installed CLIs resolve. The npm ~/.npmrc min-release-age=7 cooldown stays as defense-in-depth, since npm ships with Node and still runs for ad-hoc/project/tool installs. verify.sh now checks pnpm presence and its minimumReleaseAge on both platforms. Refs #23 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Follow-up to #23 — adopt pnpm as the daily-driver package managerPer discussion, switched from npm to pnpm for global installs while keeping the npm cooldown as defense-in-depth. Why pnpm: pnpm 11 ships supply-chain cooldown as a default and adds per-package exclusions ( Patch (commit
Checks: Exclusions ( |
pnpm 11 defaults the global bin dir to $PNPM_HOME/bin when global-bin-dir is unconfigured, so `pnpm add -g` failed with "global bin directory is not in PATH". Point PATH at $PNPM_HOME/bin (not $PNPM_HOME) in both setup scripts, both zshrc configs, and both verify scripts. Verified live: `pnpm add -g codeburn` resolves to ~/.local/share/pnpm/bin/codeburn. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Fixups from a real install test
|
shellcheck errors with SC1071 on zsh scripts (e.g. macOS/*.sh), blocking edits to files it can't lint anyway. Bail out early when the shebang is zsh, matching the .pre-commit-config.yaml exclusion of macOS/. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
linux-desktop installed tmux but never deployed a config, so it ran defaults (mouse off) — no scroll-wheel support. Deploy a tmux.conf (with `set -g mouse on`) the same way linux-server does, with backup-on-change, plus a verify check. Remove the `prefix C-a` remap from the shared config (both server and desktop) — keep the default C-b so existing muscle memory (C-b w, etc.) is preserved. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Summary
agentic-ai/Claude/install.sh: auto-installsrailguardvia cargo on fresh setupagentic-ai/Claude/README.md: documents railguard hook,post-test-runner.sh, and updated activation stepsagentic-ai/Claude/TODO.md: safeguard validation checklist and sandbox revisit items tied to upstream issue #44180What's coming
linux-desktop/updates for CachyOS/Arch supportTest plan
install.shon a fresh CachyOS machine and verify railguard installs and hooks wire upagentic-ai/Claude/TODO.mdchecklist.git/config)🤖 Generated with Claude Code