The committed ~/.local/bin/claude symlink targets a specific Claude Code
version path (whatever was current when this snapshot was taken). On any
host that has Claude Code installed at a different version, that symlink
arrives dangling.
Old behavior: just delete the dangling link and rely on the Claude
installer to recreate it. That doesn't help when the host has Claude
installed but at a version other than the one in the snapshot, and we
also support skipping the installer via DRUNKENDOTFILES_SKIP_CLAUDE=1
(used when the binary is already on disk but at a different version).
New behavior: when the deployed symlink is dangling, scan
~/.local/share/claude/versions/ and repoint the symlink to the highest
installed version (semver sort). Only fall back to deleting the link if
no version is installed at all.
The previous deploy_one() did `mv $HOME/<dir> $BACKUP_DIR/<dir>` then
`cp -a $YADR_DIR/<dir> $HOME/<dir>` for every entry in PERSONAL_DIRS.
For dirs the repo only partially populates (notably .local — repo only
tracks .local/bin/), this swept away unrelated user data: the most
recent re-bootstrap moved ~/.local/share/fonts/ (Intel One Mono, Open
Gorton, Roboto Mono, GALLAUDET, code128) into the timestamped backup,
making them appear missing.
Rework deploy logic:
- deploy_file: copies one file/symlink, backing up only the conflicting
destination (if any). Idempotent via paths_equivalent() so re-runs
with no changes produce no output and no spurious backups.
- deploy_dir: walks the repo's tree for that dir and deploys each leaf
via deploy_file. Files in $HOME the repo doesn't know about are left
untouched. Subdirs are mkdir'd as needed.
Also: track the personal fonts at .local/share/fonts/ so they redeploy
on every install, and run fc-cache -f at the end so apps see them
without a logout/login.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adds a step after personal-dotfile deploy that runs Anthropic's
official one-liner installer (curl -fsSL https://claude.ai/install.sh | bash)
when no 'claude' binary is found. No-ops if claude is already on the
machine. Opt out with DRUNKENDOTFILES_SKIP_CLAUDE=1. Install failures
are non-fatal — the rest of the flow still completes.
README: document the new step + the opt-out env var + curl in the
required tools list.
install.sh: use --recurse-submodules on the initial clone, and always
run 'git submodule update --init --recursive' before rake install so a
fresh checkout doesn't leave zsh/prezto empty.
README: document --recurse-submodules for manual clones; mention the
recovery command for existing shallow clones.
Fixes: bad math expression errors and 'no such file or directory:
~/.zprezto/runcoms/zshrc' on fresh shell startup when the Prezto
submodule hadn't been initialized.
install.sh: curl-pipe installer that clones to ~/.yadr, runs YADR's
native rake install, then layers personal dotfiles on top of $HOME
with backups on collision.
README.md: replace YADR's upstream readme with drunkendotfiles-
specific usage docs, credit, and refresh-from-upstream instructions.
Instead of asking the user to clone the repo and running rake
install, there's is now an easy .sh script that can be downloaded
and invoked in a single line.
The script takes a parameter "ask" if the use prefers to control
which modules of yadr are installed.