···11+# tg → gh feature-parity — progress
22+33+Goal: close the gap to *rough* parity with GitHub's `gh`, implementing every capability the
44+Tangled platform supports and documenting the hard limits. Full plan/rationale:
55+`~/.claude/plans/identify-the-missing-features-foamy-spring.md`.
66+77+Decisions: phased (core-writes-first) · strictly mirror `gh` (no native-only
88+star/follow/vouch/profile) · state mutations gated behind a verification spike.
99+1010+## Legend
1111+- [ ] not started · [~] in progress · [x] done
1212+1313+## Shared plumbing
1414+- [x] `DeleteRecord` helper in `atproto/records.go` (`com.atproto.repo.deleteRecord`)
1515+- [x] `UploadBlob` helper in `atproto/records.go` (`com.atproto.repo.uploadBlob`)
1616+1717+## Phase 0 — verification spike (gates Phase 3)
1818+- [x] Confirm write path: issue close/reopen
1919+- [x] Confirm write path: pr close/reopen/merge
2020+- [x] Confirm mechanism: repo delete + repo fork
2121+- [x] Confirm `sh.tangled.repo.issue.comment` / `.pull.comment` record shapes
2222+- [x] Add required scopes in `atproto/auth.go` `DefaultScopes` (re-login required)
2323+2424+## Phase 1 — core writes
2525+- [x] `issue create` (`internal/cli/issue_create.go`)
2626+- [x] `issue comment` (`internal/cli/issue_comment.go`)
2727+- [x] `pr comment` (`internal/cli/pr_comment.go`)
2828+- [x] `pr diff` (`internal/cli/pr_diff.go`)
2929+- [x] `repo edit` (`internal/cli/repo_edit.go`)
3030+- [x] `repo set-default-branch` (`internal/cli/repo_set_default_branch.go`)
3131+- [x] `ssh-key delete` (`internal/cli/ssh_key_delete.go`)
3232+- [x] `repo delete` (`internal/cli/repo_delete.go`)
3333+3434+## Phase 2 — pr create (complex)
3535+- [x] Patch-generation helper in `internal/gitutil/`
3636+- [x] `pr create` (uploadBlob + putRecord `sh.tangled.repo.pull`)
3737+3838+## Phase 3 — state mutations (only if Phase 0 is go)
3939+- [x] `issue close` / `issue reopen` / `issue edit`
4040+- [x] `pr close` / `pr reopen` / `pr edit`
4141+- [x] `pr merge` (knot RPC + status record)
4242+- [x] Add required rpc scopes to `DefaultScopes` (note: forces re-login)
4343+4444+## Deferred
4545+- [ ] `pr checkout`: needs an immutable base commit/ref before it can safely materialize a PR in an isolated worktree
4646+4747+## Phase 4 — parity & convenience
4848+- [x] `browse`
4949+- [x] `completion` (Cobra built-in)
5050+- [x] `auth token`
5151+- [x] `api` raw XRPC passthrough
5252+- [x] `repo fork`
5353+- [ ] `search` (scoped to Bobbin's supported filters)
5454+- [ ] `auth switch` (deferred — needs multi-account state refactor)
5555+- [ ] README: document new commands + hard-limit list
5656+5757+## Hard limits (excluded)
5858+`release`, `gist`, `workflow`/`run` (CI/spindle — no query API/scope),
5959+`repo archive`/`sync`/`rename`, `pr checks`, projects/codespaces, `gh status` dashboard,
6060+native-only star/follow/vouch/profile.
+29-3
README.md
···11# tg
2233-`tg` is a command-line client for [Tangled](https://tangled.org), the git forge built on atproto. It is an analogue to the GitHub CLI (`gh`), (for now) built against the read-only [Bobbin](https://docs.tangled.org/bobbin) XRPC API.
33+`tg` is a command-line client for [Tangled](https://tangled.org), the git forge built on atproto. It is an analogue to the GitHub CLI (`gh`), using Bobbin for reads and authenticated PDS/knot writes.
4455## Installation
66···50505151# List issues for an explicit repository
5252tg issue list microcosm.blue/microcosm-rs
5353+5454+# Create, comment on, and update an issue
5555+tg issue create --repo microcosm.blue/microcosm-rs --body "Details" "Bug report"
5656+tg issue comment <rkey> --body "I can reproduce this"
5757+tg issue close <rkey>
5858+tg issue reopen <rkey>
5959+tg issue edit <rkey> --title "Updated title"
5360```
54615562### Pull Requests
···5865# List pull requests
5966tg pr list
60676161-# Check out a pull request as detached HEAD
6262-tg pr checkout 3mporttfqez22
6868+# Create, comment on, inspect, and update pull requests
6969+tg pr create --title "Add feature" --base main
7070+tg pr diff <rkey>
7171+tg pr comment <rkey> --body "Looks good"
7272+tg pr close <rkey>
7373+tg pr merge <rkey>
6374```
7575+7676+### Other commands
7777+7878+`tg repo edit`, `tg repo set-default-branch`, `tg repo delete --yes`, `tg repo fork`,
7979+`tg ssh-key delete`, `tg browse`, `tg completion`, `tg auth token`, and `tg api` are available.
8080+8181+Changing scopes requires existing users to run `tg auth login` again.
8282+8383+## Platform limits
8484+8585+Tangled currently has no API for releases, gists, workflows/runs, repository archive/sync/rename,
8686+PR checks, projects, codespaces, a status dashboard, or global text search. `tg pr checkout` is
8787+deferred until PRs expose an immutable base commit/ref, allowing a safe isolated-worktree
8888+implementation. `auth switch` is deferred because the local auth store currently supports one
8989+account.
64906591## Architecture
6692