ai-project-boilerplate 1.3.0 → 1.3.2

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.
package/bin/cli.js CHANGED
@@ -110,24 +110,37 @@ async function checkForUpdate() {
110
110
  const bold = (s) => `\x1b[1m${s}\x1b[0m`;
111
111
  const dim = (s) => `\x1b[2m${s}\x1b[0m`;
112
112
 
113
- const tag = bold(yellow("UPDATE AVAILABLE"));
114
- const from = dim(CURRENT_VERSION);
115
- const arrow = "";
116
- const to = bold(cyan(latest));
117
- const cmd = bold(cyan("npm install -g ai-project-boilerplate"));
118
- const url = cyan(`https://github.com/${REPO}/releases/tag/v${latest}`);
119
- const line1 = ` ${tag} ${from} ${arrow} ${to}`;
120
- const line2 = ` Run ${cmd} to update`;
121
- const line3 = ` See what's changed: ${url}`;
122
-
123
- const strip = (s) => s.replace(/\x1b\[[0-9;]*m/g, "");
124
- const width = Math.max(strip(line1).length, strip(line2).length, strip(line3).length) + 2;
125
- const border = yellow("─".repeat(width));
113
+ const strip = (s) => s.replace(/\x1b\[[0-9;]*m/g, "");
114
+
115
+ const isPnpm = __filename.includes("pnpm");
116
+ const prefs = loadPrefs();
117
+
118
+ const updateCmd = (isPnpm || !prefs.suppressPnpmWarning)
119
+ ? bold(cyan("pnpm add -g ai-project-boilerplate"))
120
+ : bold(cyan("npm install -g ai-project-boilerplate"));
121
+
122
+ const tag = bold(yellow("UPDATE AVAILABLE"));
123
+ const from = dim(CURRENT_VERSION);
124
+ const to = bold(cyan(latest));
125
+ const url = cyan(`https://github.com/${REPO}/releases/tag/v${latest}`);
126
+
127
+ const lines = [
128
+ ` ${tag} ${from} → ${to}`,
129
+ ` Run ${updateCmd} to update`,
130
+ ` See what's changed: ${url}`,
131
+ ];
132
+
133
+ if (!isPnpm && !prefs.suppressPnpmWarning) {
134
+ lines.push(` To suppress pnpm suggestion: ${bold(cyan("ai-project --no-pnpm-warning"))}`);
135
+ }
136
+
137
+ const width = Math.max(...lines.map(l => strip(l).length)) + 2;
138
+ const border = yellow("─".repeat(width));
126
139
 
127
140
  console.error(`\n${yellow("┌")}${border}${yellow("┐")}`);
128
- console.error(`${yellow("│")} ${line1.padEnd(line1.length + width - strip(line1).length - 1)}${yellow("│")}`);
129
- console.error(`${yellow("│")} ${line2.padEnd(line2.length + width - strip(line2).length - 1)}${yellow("│")}`);
130
- console.error(`${yellow("│")} ${line3.padEnd(line3.length + width - strip(line3).length - 1)}${yellow("│")}`);
141
+ for (const line of lines) {
142
+ console.error(`${yellow("│")} ${line.padEnd(line.length + width - strip(line).length - 1)}${yellow("│")}`);
143
+ }
131
144
  console.error(`${yellow("└")}${border}${yellow("┘")}\n`);
132
145
  return true;
133
146
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-project-boilerplate",
3
- "version": "1.3.0",
3
+ "version": "1.3.2",
4
4
  "description": "CLI to scaffold AI-collaborated projects with stage-based AI instruction files",
5
5
  "bin": {
6
6
  "ai-project": "bin/cli.js"
@@ -14,35 +14,16 @@
14
14
  - `feature/<short-description>` — for new functionality
15
15
  - `fix/<short-description>` — for bug fixes
16
16
  ### PR Flow
17
- ```bash
18
- # 1. Create and switch to branch
19
- git checkout -b feature/<short-description>
20
-
21
- # 2. Implement, commit changes, then push
22
- git push -u origin feature/<short-description>
23
-
24
- # 3. Create PR
25
- gh pr create --title "<title>" --body "$(cat <<'EOF'
26
- ## Summary
27
- - <bullet points>
28
-
29
- ## Test plan
30
- - [ ] <manual test steps>
31
- EOF
32
- )"
33
-
34
- # 4. Check CI status
35
- gh pr checks
36
-
37
- # 5. Merge and delete branch after approval
38
- gh pr merge --squash --delete-branch
39
- ```
17
+ 1. Create a feature or fix branch and push to remote
18
+ 2. Open a pull request targeting `main` (e.g. via `gh pr create` or your Git host's UI)
19
+ 3. Check CI status (e.g. `gh pr checks`)
20
+ 4. Merge and delete the branch after approval (e.g. `gh pr merge --squash --delete-branch`)
40
21
 
41
22
  ### Release Flow
42
- ```bash
43
- # Bump version, tag, and create GitHub release
44
- ./scripts/release.sh <patch|minor|major>
45
- ```
23
+ 1. Bump the version (follow your project's versioning convention)
24
+ 2. Commit the version change and tag the commit (e.g. `vX.Y.Z`)
25
+ 3. Push the tag to remote
26
+ 4. Publish / deploy (e.g. create a release on your Git host, publish to a registry, deploy to an environment)
46
27
 
47
28
  ## Key Conventions
48
29
  <!-- Naming, file organization, patterns to follow -->