Skip to content

feat: bulk fetch (F) + core test suite & CI#31

Open
Bharath-code wants to merge 6 commits into
mainfrom
feat/bulk-fetch-and-tests
Open

feat: bulk fetch (F) + core test suite & CI#31
Bharath-code wants to merge 6 commits into
mainfrom
feat/bulk-fetch-and-tests

Conversation

@Bharath-code

Copy link
Copy Markdown
Owner

Summary

Two related improvements: a bulk fetch action that turns git-scope from a viewer into a tool, plus the test suite and CI the repo was missing.

1. Bulk fetch all repos (F)

  • New internal/gitops package for bulk git actions, kept separate from the read-only gitstatus package (clean read/write boundary).
  • FetchAll runs git fetch concurrently across all repos with bounded workers and a per-repo timeout, classifying each as success / failed / skipped (no remote — skipped, not failed, to avoid noise on local-only repos).
  • Press F in the dashboard → all remotes update → statuses refresh so ahead/behind counts update immediately.
  • Fetch is network-only and non-destructive, so it runs without a confirmation prompt. That pattern is reserved for the destructive actions next on the roadmap (bulk pull / stash).
  • Fulfills the roadmap item "Quick actions (bulk pull/fetch)" (fetch half).

2. Core test suite + CI

  • Table-driven unit tests for pure logic (porcelain parsing, path expansion, ignore matching, summary formatting) and real-git integration tests (temp repos via t.TempDir(), auto-skipped when git is absent).
  • Coverage on core logic: gitstatus 93% · scan 91% · gitops 85% · config 82% · cache 77%.
  • New CI workflow runs gofmt, go vet, go test -race -cover, and golangci-lint on every push and PR. Added a CI badge to the README.

Verification

  • go build, gofmt -l, go vet, and full go test ./... all pass locally.
  • Fetch verified end-to-end by an integration test that stands up a bare remote + clone.

Notes

  • Keybinding F (shift+f) avoids the existing lowercase f (filter).
  • coverage.out and a local notes file are added to .gitignore.

🤖 Generated with Claude Code

Bharath-code and others added 2 commits June 14, 2026 12:48
Add table-driven + real-git integration tests for the config, cache,
gitstatus, and scan packages (76-93% coverage on core logic). Add a CI
workflow running gofmt, go vet, go test -race -cover, and golangci-lint
on every push and PR.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add internal/gitops package for bulk git actions, kept separate from the
read-only gitstatus package. FetchAll runs 'git fetch' concurrently
(bounded workers, per-repo timeout), classifying each repo as success,
failed, or skipped (no remote).

Press 'F' in the dashboard to fetch every repo's remote; statuses are
refreshed afterward so ahead/behind counts update immediately. Fetch is
network-only and non-destructive, so it runs without a confirmation
prompt (reserved for future destructive actions like pull/stash).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@kilo-code-bot

kilo-code-bot Bot commented Jun 14, 2026

Copy link
Copy Markdown

Kilo Code Review could not run — your account is out of credits.

Add credits or switch to a free model to enable reviews on this change.

Bharath-code and others added 4 commits June 14, 2026 13:01
Bump the go directive to 1.26.0 and switch the release workflow to
go-version-file so it tracks go.mod. Remove unused style vars and the
dead logo()/getPanelHelp() functions flagged by golangci-lint's unused
linter; golangci-lint now reports 0 issues.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The action's prebuilt golangci-lint is compiled with an older Go and
refuses to analyze Go 1.26 code. install-mode: goinstall builds it with
the runner's toolchain instead.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Avoid non-deterministic lint runs from version: latest, where a new
golangci-lint release could fail an unchanged PR. Bumps are now a
deliberate, reviewable change.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Action v6 targets golangci-lint v1 and builds the wrong module path
(cmd/golangci-lint instead of v2/cmd/golangci-lint) under goinstall with
a pinned v2 version. v9 supports golangci-lint v2.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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