@slahon/lazykit 1.2.0 → 1.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +132 -72
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,72 +1,132 @@
1
- # 🦥 LazyKit
2
-
3
- **Drop an issue, get a PR.**
4
-
5
- LazyKit wires Claude AI into your GitHub repo so that when you label an issue, Claude reads it, writes the code, and opens a pull request — while you do something else.
6
-
7
- ## Quickstart
8
-
9
- ```bash
10
- npx @slahon/lazykit@latest init
11
- ```
12
-
13
- Run this inside your project folder. It will:
14
- - Create `.github/workflows/lazykit.yml`
15
- - Create `CLAUDE.md` with project context for Claude
16
- - Create the trigger label on GitHub
17
- - Print the one manual step (adding your Claude token)
18
-
19
- ## Requirements
20
-
21
- - Node.js 18+
22
- - A GitHub repository
23
- - A Claude Pro or Max subscription ([claude.ai](https://claude.ai))
24
- - Claude Code installed locally (`npm install -g @anthropic-ai/claude-code`)
25
- - GitHub CLI (`gh`) optional but recommended
26
-
27
- ## How it works
28
-
29
- 1. You open a GitHub issue describing what you want
30
- 2. You apply the `lazykit` label (or whatever you named it)
31
- 3. A GitHub Actions workflow fires and runs Claude Code
32
- 4. Claude reads the issue, explores your codebase, writes the changes
33
- 5. Claude opens a pull request with a title and description
34
- 6. You review and merge
35
-
36
- ## Authentication
37
-
38
- LazyKit uses your Claude Pro/Max subscription via an OAuth token — no pay-per-token API billing.
39
-
40
- After running `npx lazykit init`, you need to:
41
-
42
- 1. Generate your token:
43
- ```bash
44
- claude setup-token
45
- ```
46
-
47
- 2. Add it to your repo as a secret named `CLAUDE_CODE_OAUTH_TOKEN`
48
-
49
- ## CLAUDE.md
50
-
51
- LazyKit creates a `CLAUDE.md` file at your repo root. This is Claude's project guide — it tells Claude about your stack, conventions, and what commands to run before opening a PR. Edit it to match your actual project.
52
-
53
- ## Options
54
-
55
- During `npx lazykit init` you will be asked:
56
-
57
- | Option | Default | Description |
58
- |--------|---------|-------------|
59
- | Label name | `lazykit` | The GitHub label that triggers Claude |
60
- | Stack | — | Your tech stack (goes into CLAUDE.md) |
61
- | Lint command | `npm run lint` | Run before every PR |
62
- | Test command | `npm test` | Run before every PR |
63
-
64
- ## Tips
65
-
66
- - **Keep issues small and specific.** "Add a /health endpoint that returns `{ status: 'ok' }`" works great. "Rewrite the auth system" does not.
67
- - **Edit CLAUDE.md** to describe your folder structure, naming conventions, and any rules Claude must follow.
68
- - The `lazykit` label is your control switch — Claude only runs when you apply it, so you stay in charge.
69
-
70
- ## License
71
-
72
- MIT
1
+ # 🦥 LazyKit
2
+
3
+ **Drop an issue, get a PR.**
4
+
5
+ LazyKit wires Claude AI into your GitHub repo so that when you open an issue, Claude reads it, writes the code, and opens a pull request — while you do something else.
6
+
7
+ ## Quickstart
8
+
9
+ ```bash
10
+ npx @slahon/lazykit@latest init
11
+ ```
12
+
13
+ Run this inside your project folder. That's it. LazyKit handles everything else automatically.
14
+
15
+ ## Requirements
16
+
17
+ - Node.js 18+
18
+ - A GitHub repository with a remote set up
19
+ - A Claude Pro or Max subscription ([claude.ai](https://claude.ai))
20
+ - Claude Code installed locally (`npm install -g @anthropic-ai/claude-code`)
21
+ - GitHub CLI (`gh`) — required for full automation (`brew install gh` / [cli.github.com](https://cli.github.com))
22
+
23
+ ## How it works
24
+
25
+ 1. You open a GitHub issue using the **LazyKit Task** template
26
+ 2. Claude starts working on it automatically (or when you apply the label — your choice)
27
+ 3. Claude reads the issue, explores your codebase, writes the changes
28
+ 4. Claude opens a pull request with a title and description
29
+ 5. You review and merge
30
+
31
+ You can also mention `@claude` in any issue comment to give follow-up instructions or re-trigger Claude mid-thread.
32
+
33
+ ## What `init` does
34
+
35
+ Running `npx @slahon/lazykit@latest init` fully sets up your repo — no manual steps required:
36
+
37
+ | Step | What happens |
38
+ |------|-------------|
39
+ | Detects repo | Reads your `git remote` to find your GitHub repo |
40
+ | Detects stack | Auto-detects your tech stack from `package.json`, `go.mod`, `Cargo.toml`, etc. |
41
+ | Creates workflow | `.github/workflows/lazykit.yml` — the GitHub Actions automation |
42
+ | Creates issue template | `.github/ISSUE_TEMPLATE/lazykit.md` auto-applies the trigger label |
43
+ | Creates CLAUDE.md | Project guide so Claude understands your codebase |
44
+ | Creates label | Creates the trigger label on GitHub |
45
+ | Enables PR creation | Grants Actions permission to open pull requests |
46
+ | Sets token | Runs `claude setup-token` and stores it as `CLAUDE_CODE_OAUTH_TOKEN` in your repo secrets |
47
+ | Commits and pushes | Commits all generated files and pushes to GitHub |
48
+
49
+ ## Commands
50
+
51
+ ```bash
52
+ npx @slahon/lazykit@latest init # Set up LazyKit in your repo
53
+ npx @slahon/lazykit@latest status # Check if everything is wired up correctly
54
+ npx @slahon/lazykit@latest update # Regenerate workflow and CLAUDE.md
55
+ npx @slahon/lazykit@latest remove # Remove LazyKit from your repo
56
+ ```
57
+
58
+ ### Flags
59
+
60
+ ```bash
61
+ npx @slahon/lazykit@latest init --dry-run # Preview what would happen without writing files
62
+ npx @slahon/lazykit@latest update --dry-run # Preview changes without applying them
63
+ ```
64
+
65
+ ### `lazykit status`
66
+
67
+ Runs a health check and reports:
68
+
69
+ - Workflow file present
70
+ - Issue template present
71
+ - CLAUDE.md present
72
+ - `CLAUDE_CODE_OAUTH_TOKEN` secret exists (with age warning if over 6 months old)
73
+ - Trigger label exists on GitHub
74
+ - Actions PR creation permission is enabled
75
+ - Branch protection status on `main`
76
+
77
+ ### `lazykit update`
78
+
79
+ Re-generates `.github/workflows/lazykit.yml` (and optionally `CLAUDE.md`) without re-doing the full setup. Useful when you want to pull in changes to the workflow template. Reads your existing label name and trigger mode from the current workflow file.
80
+
81
+ ### `lazykit remove`
82
+
83
+ Cleanly removes LazyKit from your repo:
84
+ - Deletes the workflow file, issue template, and optionally CLAUDE.md
85
+ - Deletes the trigger label from GitHub
86
+ - Deletes the `CLAUDE_CODE_OAUTH_TOKEN` secret
87
+ - Commits and pushes the removals
88
+
89
+ ## Init options
90
+
91
+ During `npx @slahon/lazykit@latest init` you will be asked:
92
+
93
+ | Option | Default | Description |
94
+ |--------|---------|-------------|
95
+ | Label name | `lazykit` | The GitHub label that triggers Claude |
96
+ | Auto-trigger | Yes | Trigger Claude on every new issue, or only when you apply the label |
97
+ | Generate CLAUDE.md | Yes | Create a project guide for Claude |
98
+
99
+ ## Trigger modes
100
+
101
+ **Auto (default)** — Claude fires the moment a new issue is opened. No label needed.
102
+
103
+ **Label-controlled** — Claude only runs when you apply the trigger label. Use this when you want to review issues before handing them to Claude.
104
+
105
+ ## Authentication
106
+
107
+ LazyKit uses your Claude Pro/Max subscription via an OAuth token — no pay-per-token API billing.
108
+
109
+ `init` handles this automatically: it runs `claude setup-token`, captures the token, and stores it as `CLAUDE_CODE_OAUTH_TOKEN` in your repo secrets via `gh secret set`.
110
+
111
+ If the token can't be set automatically (Claude Code not installed or `gh` not available), you'll see step-by-step instructions to do it manually.
112
+
113
+ **Token expiry:** OAuth tokens can expire. Run `lazykit status` to check the age of your token. If it's expired, re-run `npx @slahon/lazykit@latest init` to generate and store a fresh one.
114
+
115
+ ## CLAUDE.md
116
+
117
+ LazyKit creates a `CLAUDE.md` file at your repo root. This is Claude's project guide — it tells Claude about your stack, coding conventions, and rules to follow. Edit it to match your actual project for best results.
118
+
119
+ ## Branch protection
120
+
121
+ If your `main` branch has protection rules enabled, Claude's pull requests will be opened but **cannot be auto-merged** — they will require manual review and approval. LazyKit detects this during `init` and `status` and warns you.
122
+
123
+ ## Tips
124
+
125
+ - **Keep issues small and specific.** "Add a `/health` endpoint that returns `{ status: 'ok' }`" works great. "Rewrite the auth system" does not.
126
+ - **Edit CLAUDE.md** to describe your folder structure, naming conventions, and any rules Claude must follow.
127
+ - **Use `@claude` in comments** to give Claude follow-up instructions or corrections without opening a new issue.
128
+ - **Run `lazykit status`** if something stops working — it pinpoints exactly what's misconfigured.
129
+
130
+ ## License
131
+
132
+ MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@slahon/lazykit",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "Drop an issue, get a PR. AI-powered issue-to-PR automation using Claude.",
5
5
  "bin": {
6
6
  "lazykit": "./index.js"