You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs: improve template setup instructions with automated secret configuration (#72)
* docs: improve template setup instructions with automated secret configuration
- Add instructions for setting GitHub secrets using 1Password CLI
- Document process for setting APP_ID and APP_PRIVATE_KEY from Mixiebot GitHub entry
- Clarify that CLAUDE_CODE_OAUTH_TOKEN requires user to run /install-github-app command
- Add detailed steps for npm Trusted Publishing OIDC setup
- Improve formatting and clarity of setup checklist
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* Update instructions
---------
Co-authored-by: Claude <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: CLAUDE.md
+89-9Lines changed: 89 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,10 +1,8 @@
1
-
# CLAUDE.md
2
-
3
-
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
1
+
This file provides guidance to agentic coding tools when working with code in this repository.
4
2
5
3
## ⚠️ Template Setup Required
6
4
7
-
**This is currently a template repository.** If you see this message, you need to set up a new project by updating the following:
5
+
**This is currently a template repository.** If you see this message, check if this is a new repo based on the template, by seeing if the git remote is ascorbic/library-template. If not, you need to set up a new project by updating the following:
8
6
9
7
1.**Package names**: Update `@ascorbic/example` in all `package.json` files to your new package name
10
8
2.**Repository URLs**: Update git repository URLs in `package.json` files. Check the current git remote for this.
@@ -15,11 +13,93 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
15
13
7.**Changeset configuration** in `.changeset/config.json`:
16
14
- Update `repo` field from `ascorbic/library-template` to your actual repository (e.g., `yourname/yourrepo`)
17
15
- Review the `ignore` array and remove/update package names as needed for your project
18
-
8.**GitHub Secrets**: Set up required secrets in GitHub repository settings:
19
-
-`APP_PRIVATE_KEY` - GitHub App private key for release workflow
20
-
-`APP_ID` - GitHub App ID for release workflow
21
-
-`CLAUDE_CODE_OAUTH_TOKEN` - Claude Code OAuth token for PR assistant
22
-
9.**npm Trusted Publishing**: Configure trusted publishing on npmjs.com for your packages to enable OIDC authentication (no NPM_TOKEN needed)
16
+
8.**Release workflow**: Activate the release workflow by renaming it:
10.**GitHub Secrets**: Set up required secrets using 1Password CLI and GitHub CLI:
21
+
22
+
```bash
23
+
# Authenticate to 1Password (use my.1password.com account)
24
+
eval$(op signin --account my.1password.com)
25
+
26
+
# Set GitHub App secrets from "Mixiebot GitHub" entry
27
+
op item get "Mixiebot GitHub" --account my.1password.com --fields "app id"| gh secret set APP_ID
28
+
op item get "Mixiebot GitHub" --account my.1password.com --fields "private key"| gh secret set APP_PRIVATE_KEY
29
+
```
30
+
31
+
For `CLAUDE_CODE_OAUTH_TOKEN`: Tell the user to open Claude Code and run the `/install-github-app` command, which will guide them through setting up the GitHub app and automatically add the secret to their repository. Note: The user must be a repository admin to install the GitHub app and add secrets.
32
+
33
+
11.**npm Trusted Publishing**: The user must manually configure trusted publishing on npmjs.com for their packages to enable OIDC authentication (no NPM_TOKEN needed). Tell them to:
34
+
1. Publish a 0.0.0 version of the package locally (one-time setup)
35
+
2. Navigate to the package page on npmjs.com
36
+
3. Click on "Settings"
37
+
4. Follow the GitHub authentication flow
38
+
5. Enter the repository name and `release.yml` as the workflow name
39
+
40
+
12.**Repository Settings and Branch Protection**: Configure repository settings and branch protection rules using the GitHub CLI. Get the current repository name first:
0 commit comments