docs/cli: Remove doc pages for removed src-cli commands - #1886
Open
marcleblanc2 wants to merge 1 commit into
Open
docs/cli: Remove doc pages for removed src-cli commands#1886marcleblanc2 wants to merge 1 commit into
marcleblanc2 wants to merge 1 commit into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
The docs sync from sourcegraph/sourcegraph (doc/_generated.push.sh) only copies generated pages into docs/cli/; it never deletes, so pages for commands removed from src-cli have lingered. Remove them. Removed from src-cli: - extensions/* (src-cli#1173), lsif (#1147), scout (#1196), sbom + signature (#1273), admin (#1309), validate (#1310) Never shipped: - prompts/* documented src-cli#1168, which was closed unmerged Stale duplicates shadowing generated pages: - auth.mdx and codeowners.mdx collide with auth/index.mdx and codeowners/index.mdx on the same route; contentlayer picked the stale flat files, hiding the generated group pages. Amp-Thread-ID: https://ampcode.com/threads/T-01a08410-86ca-72be-9928-2810e837fae1 Co-authored-by: Amp <amp@ampcode.com>
marcleblanc2
force-pushed
the
cli-refs/remove-stale-command-pages
branch
from
September 9, 2026 03:55
3032bf5 to
dd1683d
Compare
This was referenced Sep 9, 2026
marcleblanc2
added a commit
that referenced
this pull request
Sep 9, 2026
Teams were removed in Sourcegraph 7.0; src-cli#1376 removes the command. No redirect, per the same call as #1886. Part of https://linear.app/sourcegraph/issue/FE-502 Amp-Thread-ID: https://ampcode.com/threads/T-01a08410-86ca-72be-9928-2810e837fae1 Co-authored-by: Amp <amp@ampcode.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The docs sync from
sourcegraph/sourcegraph(doc/_generated.push.sh) doescp -R -L doc/cli/** _clone/docs/cli/— it only adds and updates pages, never deletes. So when a command is removed from src-cli, its reference page lingers here forever. Replaying the sync againstmainshows zero drift in the 62 generated pages, but 36 files underdocs/cli/references/are never written by it.This PR deletes the 28 that are stale. No redirects are added; none of these pages are linked from anywhere in the site.
Removed (28 files)
Command removed from src-cli
extensions/{index,copy,delete,get,list,publish}lsifsrc code-intel upload)scoutsbom,signatureadminvalidateCommand never shipped
prompts+ 13 subcommand pages (#1155) documented sourcegraph/src-cli#1168, which was closed unmerged.Stale duplicates shadowing generated pages
auth.mdxandcodeowners.mdxcollide withauth/index.mdx/codeowners/index.mdx: contentlayer flattens both tocli/references/auth, andallPosts.findreturned the stale flat file. After this change/cli/references/authand/cli/references/codeownersrender the generated group pages (verified withcontentlayer build).Kept
search-jobs/{cancel,create,delete,get,list,logs,restart,results}— the subcommands exist, butsrc doconly emits a singlesearch-jobs.mdbecausesearchJobsCommandsisn't in thecommandersmap incmd/src/doc.go. Fix belongs upstream.Verification
npx tsc --noEmitpassesnpx contentlayer buildgenerates 493 docs;cli/references/authandcli/references/codeownersnow resolve to theindex.mdxfilesdocs/orsrc/Follow-up (upstream)
To stop this recurring,
_generated.push.shshould mirrordocs/cli/references/(delete-then-copy) instead of copying over it. Done in sourcegraph/sourcegraph#15529 (merge after sourcegraph/sourcegraph#15528 and #1889).Amp threads