Agentic Dotfiles
My development setup for working with coding agents across the terminal, editor,
and shell.
It brings together shared instructions, reusable skills, specialized agent roles,
client configuration for Codex, Claude Code, and Grok, plus the shell and tool
settings that support the workflow. Use the repository as a starting point: adopt
the pieces that fit how you work and change the rest to suit your machine and
preferences.
Highlights
- Shared working principles across Codex, Claude Code, and Grok
- Specialized explorer, support worker, reviewer, and council agent roles
- Reusable skills for planning, implementation, review, documentation, and handoff
- Hooks that keep agent behavior consistent across a coding session
- Fish as the primary shell, with shared daily behavior mirrored into Zsh
- Terminal and editor configuration for a keyboard-driven workflow
- Small local utilities for project checks and agent-assisted development
Where to Start
The CONTEXT-*.md files are maps for the less obvious parts of the setup. They
explain which files own agent instructions, hooks, lifecycle behavior, and shared
shell behavior.
Image paste in remote sessions
Run setup on both computers to install the yusing/mosh fork,
then connect from the computer holding the image:
In Mekugi, press Ctrl+^ followed by i to attach a clipboard PNG over the
existing encrypted Mosh connection. Ctrl+^ followed by c cancels capture or
upload. Ordinary paste keys are unchanged. The client needs wl-paste on
Wayland or xclip on X11; macOS uses its built-in osascript. Both ends must
run the fork.
Images can be up to 64 MiB. Mosh shows progress, keeps typing and screen updates
responsive, and delivers one bracketed image-path paste after upload succeeds.
Mekugi recognizes that path as an attachment; other applications need equivalent
image-path attachment support. An interrupted upload resumes while the same
client and server remain alive, but does not survive restarting either process.
Incomplete files are removed on cancellation, failure, or server exit. Completed
private image files remain in remote temporary storage for pending drafts and
follow the host's normal temporary-file cleanup policy.
Setup stops the old clip-watch, clip-recv, and clip-xvfb services and the
macOS watcher, and moves remaining legacy launch files and helpers into
~/.local/share/dotfiles-setup/retired-clipboard/. It leaves Tailscale operator and
linger settings unchanged because other tools may use them.
Install and upgrade
Review setup.json before running setup. It installs tools and
configures this home checkout. Run as a regular user. Setup installs a root-owned
helper and a per-user passwordless sudo rule for package and login-shell operations.
The first installation or a helper update may request authentication; subsequent
runs reuse the authorization. These files remain installed under /etc/.
Homebrew installation and upgrade confirmations are disabled.
Checkout collisions are backed up under ~/.local/share/dotfiles-setup/.
Copy selected files instead if you want to retain your own dotfiles.
For a new machine that should become a checkout of this repository:
curl -fsSL https://raw.githubusercontent.com/yusing/agentic-dotfiles/main/setup.sh | bash
Linux and macOS use native installation. After setup, upgrade managed tools with:
Tool sources
Arch prefers Homebrew for standalone tools (including Go, Bun, Fish, rustup,
rust-analyzer, sccache, Zsh plugins, PostgreSQL 18, and CLI utilities) and uses
pacman only for packages depended on by other Arch system packages (such as
Python, Node.js, LLVM/Clang, Git, Bash, Curl, OpenSSH, Docker, core build
tools, and Chromium/WebKitGTK libraries). Other platforms retain their Homebrew
sources. Formulae follow Brew's stable channel. Brew uses available prebuilt
bottles; mcdu uses its upstream tap's checksummed prebuilt archives.
On Debian and Ubuntu, setup uses Homebrew LLVM, Binutils, and Make for
selected build groups instead of APT's build-essential. APT still supplies
the host C/C++ headers and runtime libraries needed to link native binaries.
npm packages retain their npm source through Mise, including agent-browser and
markdownlint-cli. Bun performs npm installation. Mise also supplies tools
without a compatible current Brew source, including gh-dash and go-swagger,
plus pinned scriptc 0.4.10 and Lightpanda 1.0.0. The shells select Chrome as
agent-browser's default engine.
Brew supplies rustup across platforms. Manage Rust toolchains and targets
separately with rustup.
With the supplied shell configuration, Cargo keeps each workspace checkout's default build output
under ~/.cache/rust/targets/. New Git worktrees copy compatible registry and Git dependency libraries from the main
checkout's default target without taking its build lock. Workspace code, build scripts and procedural macros rebuild locally,
along with units that need their outputs. The compiler cache is shared at ~/.cache/rust/sccache.
Explicit Cargo target directories still take precedence.
Arch uses OpenBSD netcat and system Chromium/WebKitGTK 4.1 libraries.
Other Linux distributions retain GNU netcat and Brew browser libraries. WebKitGTK 6 and
Bazelisk are excluded. macOS uses its system netcat and WebKit framework.
PostgreSQL 18 comes from Homebrew with a separate Brew data directory. Setup
does not migrate or delete existing databases. Switching package sources
requires a separate database migration.
Mosh, Claude Code, Grok, Antigravity, and Devin CLI use their declared vendor installers.
Install Mekugi separately. Setup does not install standalone Codex.
Antigravity CLI installs as agy and prompts for Google sign-in on first run.
Devin CLI installs as devin; run devin auth login on first use.
Native installation
Arch prefers Homebrew for standalone tools and uses pacman for system-depended
packages, never both for the same tool. Other Linux distributions use Homebrew
plus host bootstrap prerequisites; macOS needs Xcode Command Line Tools. Setup
configures the host Fish shell and compiles managed helpers. Open a new
terminal after installation.
bash setup.sh # install missing tools (default: --tools=full)
bash setup.sh --tools=dev # interactive workstation (shell + agents + main langs + browser)
bash setup.sh --tools=agent,rust # headless agent sandbox (core + agent-core + lint + Rust)
bash setup.sh --tools=go,rust # minimal core + Go and Rust toolchains only
bash setup.sh --upgrade # upgrade managed tools
bash setup.sh --upgrade git-agent # upgrade only a named Mise tool
Normal setup retains installed versions. Use --tools=SPEC (or SETUP_TOOLS)
to select a profile (full, dev, agent, agents, core) or
comma-separated tool groups declared in setup.json. Specific
groups always include core (minimal non-interactive Git, search, and CLI
base). Use agent plus language groups (such as --tools=agent,rust or
--tools=agent,rust,browser) in headless agent sandboxes to install hooks,
skills-mgr, graphify, scriptc, and linters while skipping interactive
shells (shell), host clipboards (clipboard), mosh, and vendor agent CLIs
(agent-clis). The browser group installs agent-browser and Lightpanda,
not the Linux Chromium libraries. Add chromium for those libraries or
webkit for WebKitGTK. To provision local Chrome on x86-64 Ubuntu, run
agent-browser install --with-deps. Unselected native packages, Mise tools,
vendors, and Fish login shell setup are skipped. Helper compilation requires
both bun and scriptc. The tracked .config/mise/config.toml and
mise.lock keep their full inventory. Package managers still install
dependencies of selected tools. Full upgrades refresh declared Brew,
Mise, and vendor tools (or only the selected subset when combined with
--tools). Named upgrades accept a Mise identifier or command
name and skip Brew, vendors, helpers, and final verification.
Full setup configures the sbx_cloud SSH alias in your user SSH configuration
when Docker Sandboxes is managed. If you upgrade only sbx, rerun
sbx --cloud setup ssh to refresh the alias to use the new binary.
Full upgrades skip the Mosh source build when its installed commands identify
the fork's latest commit. Missing or unrecognized builds run the installer.
Stale-tool cleanup
Setup leaves superseded packages and old image installations in place. Validate
their native replacements before retiring old copies manually. Legacy clipboard
push services and helpers follow the image-paste retirement
described above.
Adapting the Agent Setup
Start with the instruction stack before copying client settings: