Skip to content

Add kit domain layer for Baidu Tieba#1

Open
tamnd wants to merge 1 commit into
mainfrom
feat/kit-domain
Open

Add kit domain layer for Baidu Tieba#1
tamnd wants to merge 1 commit into
mainfrom
feat/kit-domain

Conversation

@tamnd

@tamnd tamnd commented Jun 15, 2026

Copy link
Copy Markdown
Owner

Summary

  • Wire the existing tieba package into the any-cli/kit framework
  • Add domain.go with Domain struct, Register (topic resolver + hot list op), newClient factory, and Classify/Locate URI helpers
  • Add domain_test.go with offline tests for DomainInfo, Classify, Locate, and host wiring (Mint + ResolveOn round-trip)
  • Update types.go to add kit/table struct tags to Topic
  • Update tieba.go to add Host constant
  • Add github.com/tamnd/any-cli v0.2.0 dependency

Test plan

  • All 9 tests pass: go test ./tieba/...
  • Build succeeds: go build ./...
  • tieba hot lists the current hot topics from Baidu Tieba

Wires the existing tieba package into the any-cli/kit framework so the
binary and a multi-domain host share one source of truth:

- domain.go: Domain struct, Register (topic resolver + hot list op),
  newClient factory, Classify/Locate URI helpers
- domain_test.go: offline tests for DomainInfo, Classify, Locate, host
  wiring (Mint + ResolveOn round-trip)
- types.go: add kit/table struct tags to Topic
- tieba.go: add Host constant
- go.mod/go.sum: add github.com/tamnd/any-cli v0.2.0

All 9 tests pass (5 existing + 4 new domain tests).
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