Repository navigation
cut: diff, snapshots, csv/tsv and --tree go before they ever ship - #28
Merged
Merged
Conversation
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.
Closes #25. Phase 2: fewer things, done well.
None of these were ever released. v0.1.0 shipped
ports,find,free,kill,--json,--forceand--version, with no--formatat all (checked againstgit show v0.1.0:main.go). So they go with no deprecation cycle:ports diffand--format snapshot. They're clever, but they don't answer the question ports exists for.--format csvand--format tsv.--jsonplusjqcovers scripts.--tree.That's about 980 lines out.
--formatis nowtableorjson.--json,--sort, the filters and--watchare unchanged.ports --helplistsdoctor,find,here,list,stopandwait, and its usage section is 28 lines.Anyone who tries a removed feature gets a clear exit 2, with stdout empty:
ports diff before.jsonunknown command "diff" — run ports --help for the listports --treeunknown flag: --treeports --format csvunknown format "csv" (want table or json)ports find x --format tsvThat last row fixes a quirk found along the way. Listing commands used to check the format only when rendering, so
find x --format tsvsaid "nothing matching" and hid the real problem.find,here,listand--watchnow check it before scanning.One rule for
--format. A format that doesn't exist is exit 2 on every command, with or without--json.stopused to let--jsonwin over a bad format; the reviewer caught the inconsistency.How it was verified
npm run lint✓,npm run build✓.ports diff before.jsonandports --treeare on its must-fail list, so they can't creep back into the docs.TestDiffCommand, the tree tests and the TSV pin test.TestSortFlagreads the table instead of csv, and the exit-code and watch-rejection cases use commands and flags that still exist.Risk
Tier: risky (
internal/inspect/output.go,--formatvalues).Public surface: removed commands, flags and formats that were never released.
--jsonoutput is unchanged.Rollback: revert the squash commit.
A fresh-context review said ok to ship. It confirmed nothing removed was released, and that the man pages, shell completion and site links have no leftovers. Its should-fixes are the second commit:
--json+ bad--formatinconsistency (now one rule);--tree;Notes for the release
--formattakestableorjson.Generated by Claude Code