Skip to content

fix(penpal): filter ANCHORS.md from anchors source - #533

Merged
loganj merged 1 commit into
mainfrom
filter-anchors-md-from-anchors
Mar 29, 2026
Merged

fix(penpal): filter ANCHORS.md from anchors source#533
loganj merged 1 commit into
mainfrom
filter-anchors-md-from-anchors

Conversation

@loganj

@loganj loganj commented Mar 29, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • ANCHORS.md is an empty marker file with only frontmatter — not useful to display in the sidebar or index in search results
  • Adds RequireSibling field to SourceType so the scanner pre-filters files at walk time: only files in directories containing the specified sibling are included
  • The anchors source sets RequireSibling: "ANCHORS.md", which hides the marker itself (ClassifyFile returns "") and excludes stray files (e.g. a PRODUCT.md without a sibling ANCHORS.md) without relying on GroupFiles for module-membership checks

🤖 Generated with Claude Code

ANCHORS.md is an empty marker file with only frontmatter — not
interesting to display. Add RequireSibling field to SourceType so the
scanner only includes files from directories containing a specified
sibling file. The anchors source sets RequireSibling: "ANCHORS.md",
which both hides the marker and excludes stray files (e.g. a PRODUCT.md
without a sibling ANCHORS.md) at scan time rather than in GroupFiles.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@loganj
loganj merged commit 242f56c into main Mar 29, 2026
4 checks passed
@loganj
loganj deleted the filter-anchors-md-from-anchors branch March 29, 2026 23:49

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9d8ae94a44

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

return "dependencies"
default:
return "" // skip non-ANCHORS files
return "" // skip ANCHORS.md and non-ANCHORS files

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Prevent manual sources from resurfacing ANCHORS.md

Returning "" for ANCHORS.md means the anchors source no longer claims that path, so scanProjectSources never marks it as seen and a later overlapping manual tree source (for example, path: "." in project sources) will include ANCHORS.md again. In that configuration, the marker file reappears in the sidebar/search despite this change’s goal of hiding it globally, because deduplication in scanProjectSources is first-claim-wins and this source now opts out of claiming the file.

Useful? React with 👍 / 👎.

loganj added a commit that referenced this pull request Mar 30, 2026
…-file-dis

* origin/main:
  fix(penpal): ensure repo badges are generated when repos are added (#534)
  fix(penpal): show agent selector dropdown below trigger button (#532)
  fix(penpal): filter ANCHORS.md from anchors source (#533)
  fix(penpal): show wave animation in sidebar when run phase is unknown (#531)
  fix(penpal): anchor stability improvements and code block highlights (#530)
  refactor(penpal): decompose Layout.tsx into focused components (#528)

# Conflicts:
#	apps/penpal/frontend/src/components/Layout.tsx
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