Skip to content

Replace the AGENTS.md and .agents symlinks: they block Arduino Library Manager releases - #635

Merged
tyeth merged 3 commits into
adafruit:masterfrom
tyeth:fix/no-symlinks
Nov 20, 2026
Merged

tyeth merged 3 commits into
adafruit:masterfrom
tyeth:fix/no-symlinks

Conversation

@tyeth

@tyeth tyeth commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

Summary

@hathach: symlinks in a library repository block its Arduino Library Manager releases. Please check that agentrc does not need CLAUDE.md to hold the instructions text (this PR moves it to AGENTS.md). The AGENTS.md (-> CLAUDE.md) and .agents (-> .claude) symlinks added with the agent contracts mean that no Adafruit TinyUSB Library release since then has reached the Library Manager. The same pattern is probably in other Adafruit libraries that got the agent setup.

The Library Manager indexer runs arduino-lint on each new tag. It rejects any release that contains a symlink:

ERROR: Symlink(s) found. Symlinks cause difficulties for Windows users. These block addition to the Arduino Library
       Manager index:
         .../.agents
         .../AGENTS.md
       (Rule LS005)

(from the indexer log: https://downloads.arduino.cc/libraries/logs/github.com/adafruit/Adafruit_TinyUSB_Arduino/)

Effect: the Library Manager index still stops at 3.7.7; 3.8.0 is not in it. So arduino-cli lib install and the IDE install 3.7.7, and CI that installs this library gets the old version.

Change

Two commits:

  1. Replace the symlinks. AGENTS.md becomes a regular file and the .agents link is removed. A new no-symlinks pre-commit hook fails if any symlink is committed (git ls-files -s, mode 120000). I tested it: it passes on this branch and fails on master, listing .agents and AGENTS.md.
  2. One instruction file for every agent. The text of CLAUDE.md moves into AGENTS.md, and CLAUDE.md becomes @AGENTS.md (Claude Code's import). Codex and GitHub Copilot read AGENTS.md, and Claude Code reads it through the import, so all three see the same instructions without a symlink or a copy. A short "Agent files" section says this, and why there are no symlinks. Skill references to "CLAUDE.md's" sections now say AGENTS.md.

Skills stay in .claude/skills/: Claude Code and Copilot find them there (Copilot looks in .github/skills/ and .claude/skills/). Codex only searches .agents/skills/, so it does not find them by itself; AGENTS.md lists each skill's path. Making Codex find them would need copies under .agents/skills/ (kept in sync, and shipped in every release) or a local, git-ignored link made by the agent setup.

Sources: Claude Code memory (AGENTS.md), Claude Code skills, Codex skills, Copilot skills, Copilot custom instructions.

After merging

A new release tag is needed, because the Library Manager only picks up new tags.

🤖 Generated with Claude Code

…uino Library Manager

The Arduino Library Manager indexer runs arduino-lint on each new tag and
rejects a release that contains a symlink (rule LS005, "Symlinks cause
difficulties for Windows users"). AGENTS.md (-> CLAUDE.md) and .agents
(-> .claude) are symlinks, so no release since they were added has been
indexed.

- AGENTS.md is now a regular file that points agents to CLAUDE.md and
  .claude/skills/.
- The .agents link is removed.
- A no-symlinks pre-commit hook fails if a symlink is committed again.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The changes update repository agent guidance, add a pre-commit check for tracked symlinks, and change the library version from 3.8.0 to 3.8.1.

Changes: Repository guidance and checks

Layer / File(s) Summary
Update agent guidance entry points
AGENTS.md, CLAUDE.md, .agents, .claude/skills/update-tinyusb/SKILL.md
AGENTS.md documents repository guidance and identifies agent files and skills. CLAUDE.md refers to AGENTS.md, and the TinyUSB update skill uses the updated guidance references.
Document validation and PR procedures
AGENTS.md
AGENTS.md documents skill use, hardware validation, build and HIL contracts, and PR procedures.
Check tracked symlinks
.pre-commit-config.yaml
An always-running local hook checks tracked Git index entries, reports symlink paths, and exits with status 1 when it finds any.

Library release metadata

Layer / File(s) Summary
Update library version metadata
library.json, library.properties
Both files change the library version from 3.8.0 to 3.8.1.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Possibly related PRs

Suggested reviewers: hathach

Merge Risk: Minimal · up to 926f3

This change removes the symlinks that blocked Library Manager indexing, adds a guard against reintroducing them, and updates the version to 3.8.1. No concrete merge-blocking risk was identified. A new release tag is needed after merging so the index picks it up.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: replacing the AGENTS.md and .agents symlinks with regular files, with the stated reason that they block Arduino Library Manager releases. The changeset matches this. A…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description check Passed The description states the purpose of the change: symlinks in AGENTS.md and .agents block Arduino Library Manager releases. It names the affected files, the no-symlinks pre-commit hook, the move of CL…
Full details: Title check

Explanation

The title names the main change: replacing the AGENTS.md and .agents symlinks with regular files, with the stated reason that they block Arduino Library Manager releases. The changeset matches this. AGENTS.md becomes a regular file, the .agents link is removed, and a no-symlinks pre-commit hook is added. The version bumps and CLAUDE.md edits are supporting changes.

Full details: Description check

Explanation

The description states the purpose of the change: symlinks in AGENTS.md and .agents block Arduino Library Manager releases. It names the affected files, the no-symlinks pre-commit hook, the move of CLAUDE.md content into AGENTS.md, and the need for a new release tag. It matches the changeset, so the check passes.

Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between ada6018 and 926f363.

Files selected for processing: 4

  • .claude/skills/update-tinyusb/SKILL.md
  • AGENTS.md
  • AGENTS.md
  • CLAUDE.md
Files skipped from review as they are similar to previous changes: 2

  • AGENTS.md
  • AGENTS.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 0 remain after this review.

@github-actions

github-actions Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

Hardware-in-the-loop (HIL) Test Report

PR head 926f3634e7 · tested merge af453365fe · run 44793135529 attempt 1

5 pass · 2 not run

Board Build Result cdc_echo hid_inout msc_ramdisk host_device_info Restore Time Core
adafruit_fruit_jam ✅ ✅ pass ✅ ✅ ✅ — ✅ 40s rp2040:rp2040 6.4.0
espressif_p4_function_ev ✅ ✅ pass ✅ ✅ ✅ — ✅ 35s esp32:esp32 4.0.0
espressif_s3_devkitm ✅ ✅ pass ✅ ✅ ✅ — ✅ 38s esp32:esp32 4.0.0
metro_m4_express ✅ ✅ pass ✅ ✅ ✅ — ✅ 30s adafruit:samd 1.7.17
raspberry_pi_pico ✅ ✅ pass ✅ ✅ ✅ — ✅ 39s rp2040:rp2040 6.4.0
raspberry_pi_pico2 ❌ ⚪ not run — — — — — 0s rp2040:rp2040 6.4.0
raspberry_pi_pico_w ❌ ⚪ not run — — — — — 0s rp2040:rp2040 6.4.0
  • metro_m4_express: the core's bundled copy of this library differs from this checkout in src/arduino/Adafruit_TinyUSB_API.h, src/arduino/Adafruit_USBD_CDC.h, src/arduino/Adafruit_USBD_Interface.h; the result covers that mix
  • raspberry_pi_pico2: build failure
  • raspberry_pi_pico2: not run: no packed tree at /opt/actions-runner/arduino-tinyusb/_work/_temp/hil-build/raspberry_pi_pico2
  • raspberry_pi_pico_w: build failure
  • raspberry_pi_pico_w: not run: no packed tree at /opt/actions-runner/arduino-tinyusb/_work/_temp/hil-build/raspberry_pi_pico_w

Not covered by any farm board:

  • family ch32: no roster board of this family on this host
  • family nrf: no roster board of this family on this host

The battery runs serial_echo, hid_generic_inout and msc_ramdisk on device boards and host_device_info on host boards; no other example, class or family is tested here. ✅ pass · ❌ fail · ⛔ blocker (see the board's note; may need recovery) · ⚪ not run · — not part of the board's battery · ❔ unknown

@tyeth
tyeth marked this pull request as ready for review November 20, 2026 18:06
@greptile-apps

greptile-apps Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5 Tier: plus

[Medium impact] The PR appears safe to merge; no blocking issues were found.

Summary

Removes the symlinks that blocked Arduino Library Manager releases.

  • Arduino library releases no longer include agent-file symlinks.

No new actionable issues found.

Reviews (3) · Last reviewed commit: "AGENTS.md holds the agent instructions, ..." · Reviewed by Greptile

greptile-apps[bot]
greptile-apps Bot previously approved these changes Nov 20, 2026
@greptile-apps
greptile-apps Bot dismissed their stale review November 20, 2026 18:09

Dismissed because a newer commit was pushed; Greptile will re-review the current head.

greptile-apps[bot]
greptile-apps Bot previously approved these changes Nov 20, 2026
Codex and GitHub Copilot read AGENTS.md; Claude Code reads CLAUDE.md, and
reads AGENTS.md only through an import. The instructions move from
CLAUDE.md into AGENTS.md, and CLAUDE.md is now "@AGENTS.md", so all three
read the same text without a symlink. A short "Agent files" section says
where skills are (.claude/skills/, found by Claude Code and Copilot) and
why there are no symlinks. Skill references to "CLAUDE.md's" sections now
name AGENTS.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@greptile-apps
greptile-apps Bot dismissed their stale review November 20, 2026 18:28

Dismissed because a newer commit was pushed; Greptile will re-review the current head.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant