Skip to content

Extract init into package, add skills, make CIRCLE_TOKEN optional#167

Draft
schurchleycci wants to merge 2 commits intomainfrom
init-skills-and-cleanup
Draft

Extract init into package, add skills, make CIRCLE_TOKEN optional#167
schurchleycci wants to merge 2 commits intomainfrom
init-skills-and-cleanup

Conversation

@schurchleycci
Copy link
Copy Markdown
Contributor

Summary

  • Extracts init orchestration from cmd/init.go into internal/initialize/ package for cleaner cmd/internal separation
  • Adds --skip-skills flag and skill installation step to chunk init, with install/update results displayed in output
  • Makes CIRCLE_TOKEN optional: when missing (or API fails), falls back to a manual org ID text prompt instead of skipping CircleCI setup entirely
  • Passes workDir explicitly through sandbox/sync instead of calling os.Getwd() in leaf code
  • Minor cleanups: uses slog for sentinel warnings, wraps validate errors with usererr

Test plan

  • task build and task test pass (632 tests)
  • Run chunk init without CIRCLE_TOKEN — verify manual org ID prompt appears
  • Run chunk init with CIRCLE_TOKEN — verify org picker still works
  • Run chunk init --skip-circleci — verify CircleCI step is fully skipped
  • Esc/Ctrl+C at manual prompt skips gracefully

🤖 Generated with Claude Code

schurchleycci and others added 2 commits March 27, 2026 15:01
Move init orchestration from cmd/init.go into internal/initialize/ for
cleaner separation. Add --skip-skills flag and skill install results to
init output. Make CIRCLE_TOKEN optional by falling back to manual org ID
prompt. Minor cleanups: pass workDir explicitly instead of using os.Getwd
in leaf code, use slog for sentinel warnings, wrap validate errors with
usererr.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Move CircleCI org setup and command detection into setupCircleCI and
detectCommands helpers to bring Run below the gocyclo threshold.

Co-Authored-By: Claude Opus 4.6 <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