agentleFS
congmnguyencongmnguyen/claude-code-wsl2-setup/AGENTS.md

claude-code-wsl2-setup

AGENTS.md50 starsChanged 3 months agoMITView on GitHub

  • Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.

    Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.

  • In this repository3 other files it gives its agents.

The file

We split this AGENTS.md into the rules it gives an agent

5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Run screenshot paste only through the systemd user service.

    line 12
  2. Very specific:

    Run bash scripts/check.sh for shell syntax, local Markdown links, and focused behavior tests.

    line 22
  3. Distinctive:

    If a check cannot run, report that explicitly instead of claiming the change works.

    line 26
  4. Distinctive:

    Read README.md, then only the relevant component docs.

    line 30
  5. Distinctive:

    Call out Windows-side steps that WSL cannot safely apply, including Windows Terminal settings and SharpKeys remapping.

    line 32

≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

Repository instructions

Purpose

  • This repository preserves the maintainer's previous Claude Code setup for WSL2 + Windows Terminal. The maintainer now uses Ubuntu + Ghostty and no longer tests WSL2 daily. It has no build system or package manager; lightweight checks live in tests/ and scripts/; deliverables are Markdown docs, shell scripts, and config snippets.
  • The current machine's ~/.claude/ is not the source of truth for the preserved WSL2 setup. Do not synchronize it with this repository or install WSL2 components on Ubuntu as part of documentation maintenance.
  • Root *.md files document setup components; agents/ and skills/ contain optional installable artifacts. Keep optional and legacy components clearly labeled. Do not present the repository as a tested Ubuntu setup.
  • Codex skills and setup live in the separate congmnguyen/codex-wsl2-setup repository. Do not restore a Codex backup tree here.

Non-obvious constraints

  • Run screenshot paste only through the systemd user service; do not add shell or Claude hooks that can race or stop the supervised wsl-screenshot-cli process. See image-paste.md.
  • There are no PreToolUse or PostToolUse hooks in this setup, and none should be added. Every one tried here matched on patterns, and a pattern that is wrong in either direction is worse than nothing: a truncating hook destroyed the middle of failing test output, a credential-blocking hook rejected ordinary source files named token_manager.py, and a Ruff autofix hook silently deleted imports out of files Claude had just written. Prefer exact-match permissions.deny rules, which cannot misfire. See pruned-notes.md.
  • Notification hooks remain part of the documented WSL2 setup. See claude-notify.md.
  • Browser automation is no longer documented here; playwright-cli.md and the Playwright section of mcp-setup.md were removed. mcp-setup.md now covers only the project-scoped Figma Desktop MCP. Recover the old pages from git history rather than rewriting them.
  • ~/.claude/keybindings.json must be an object containing a bindings array; a bare array silently fails.
  • In ~/.claude/settings.json, merge settings instead of replacing the file. Use attribution, not deprecated or invented attribution keys. See settings.md.
  • Normalize assets/preview-*.png to a 1220x788 #0d1117 canvas and render previews at width 720 in README.md.

Verification

  • Run bash scripts/check.sh for shell syntax, local Markdown links, and focused behavior tests. These checks do not validate Windows GUI behavior.
  • Shell changes: also run a focused behavior check for any behavior not covered by the suite.
  • JSON/config changes: parse them and verify the live consumer loads them when possible.
  • Documentation changes: verify referenced paths, commands, cross-links, and consistency with the documented WSL2 scope. Do not claim WSL2 runtime verification from an Ubuntu-only check.
  • If a check cannot run, report that explicitly instead of claiming the change works.

Setup requests

  • Read README.md, then only the relevant component docs. Confirm the target environment is WSL2 before applying WSL2-specific configuration. Install requested components; leave optional or legacy components alone unless requested.
  • Preserve existing user settings while merging hooks, permissions, plugins, and statusline configuration.
  • Call out Windows-side steps that WSL cannot safely apply, including Windows Terminal settings and SharpKeys remapping.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.