Commit Graph

8 Commits

Author SHA1 Message Date
林迪文 9b08029643 merge: resolve client.go conflict, keep XML declaration fix 2026-06-03 08:58:40 +08:00
林迪文 044e736a1b fix: detectHTMLResponse 跳过 XML 声明,添加 HTML 响应检测
- 在 json.Unmarshal 之前检测 HTML 响应
- detectHTMLResponse 先 strip <?xml...?> 声明再检查 HTML 前缀
- 返回中文诊断提示替代原始 JSON parse error
- 修复 Code Review: TestDetectHTMLResponse/XML_声明后跟_HTML

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-03 08:33:52 +08:00
蒋天翔 aa0a623a73 feat: 添加 Raw API HTML 响应自动检测与诊断提示
当 GitLink API 返回 HTML 页面(如登录页)而非 JSON 数据时,
自动识别并返回结构化错误信息,包含可能原因和修复建议。

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-02 16:02:59 +08:00
wbtiger 902886cabd Merge pull request 'fix: preserve raw file API paths' (#85) from dtwdtw/gitlink-cli:fix/issue-142586-raw-file-api into master 2026-06-01 01:04:25 +08:00
wbtiger f7263cc466 chore: add golangci-lint config and fix lint issues
- Add .golangci.yml with 8 essential linters (errcheck, govet,
  ineffassign, staticcheck, unused, errorlint, gosec, misspell)
- Fix real bugs: errors.As, %w wrapping, nil map check, dead code,
  unnecessary conversion, unused parameters
- Add `make lint` target, include it in `make check` pipeline
- Update pre-commit hook to run lint step

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-31 00:37:45 +08:00
fsafasff c28b72d46f fix: preserve raw file API paths 2026-05-29 11:41:10 +08:00
wbtiger 36249f3087 feat: add PR closed time and repo README shortcuts (#49, #52)
PR #49 (dtwdtw): enrich PR view with closed_at from issue journals
- Fetches close timestamp for closed/rejected PRs
- Skips extra API call for open PRs
- 2 new tests

PR #52 (dtwdtw): add repo +readme shortcut
- Fetches README content with optional --ref and --path params
- normalizeAPIPath prevents duplicate /api prefix in client
- 4 new tests (3 client + 1 repo)

Co-authored-by: dtwdtw <dtwdtw>
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-27 00:35:31 +08:00
wbtiger e892370de8 init gitlink-cli 2026-04-17 10:01:30 +08:00