template-git-repo 0.1.24 → 0.1.25
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/package.json +1 -1
- package/template/{scripts → .github/scripts}/list-test-packages.mjs +1 -1
- package/template/{scripts → .github/scripts}/next-free-version.mjs +2 -2
- package/template/{scripts → .github/scripts}/pin-workspace-deps.mjs +1 -1
- package/template/{scripts → .github/scripts}/restore-pinned-deps.mjs +1 -1
- package/template/{scripts → .github/scripts}/workspace-build-order.mjs +1 -1
- package/template/.github/workflows/npm-publish.yml +5 -5
- package/template/.github/workflows/tests.yml +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "template-git-repo",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.25",
|
|
4
4
|
"description": "One command to set up a repo with GitHub Actions, README badges, Turborepo and Codecov — the CI setup from qwksearch-research-agent, as a template",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
* `empty` exists because GitHub fails a job whose matrix has no entries, which
|
|
23
23
|
* would make a repo with no test suites look broken rather than untested.
|
|
24
24
|
*
|
|
25
|
-
* Usage: node scripts/list-test-packages.mjs [rootDir]
|
|
25
|
+
* Usage: node .github/scripts/list-test-packages.mjs [rootDir]
|
|
26
26
|
*/
|
|
27
27
|
import fs from 'node:fs';
|
|
28
28
|
import path from 'node:path';
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
* ones — the exact numbers `latest` cannot see. The union of the two is the
|
|
24
24
|
* taken set.
|
|
25
25
|
*
|
|
26
|
-
* Usage: node scripts/next-free-version.mjs <package-name> <local-version>
|
|
26
|
+
* Usage: node .github/scripts/next-free-version.mjs <package-name> <local-version>
|
|
27
27
|
* Prints the next free version, always strictly above <local-version>. If
|
|
28
28
|
* the registry says nothing about the package (a first publish, or an
|
|
29
29
|
* unreachable registry) that is just <local-version> plus a patch.
|
|
@@ -161,7 +161,7 @@ if (import.meta.url === pathToFileURL(process.argv[1] || '').href) {
|
|
|
161
161
|
const [name, local] = process.argv.slice(2);
|
|
162
162
|
|
|
163
163
|
if (!name || !local) {
|
|
164
|
-
console.error('Usage: node scripts/next-free-version.mjs <package-name> <local-version>');
|
|
164
|
+
console.error('Usage: node .github/scripts/next-free-version.mjs <package-name> <local-version>');
|
|
165
165
|
process.exit(2);
|
|
166
166
|
}
|
|
167
167
|
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
* The edit is deliberately left in the working tree — `restore-pinned-deps.mjs`
|
|
16
16
|
* takes it back out after the publish, keeping only any version bump.
|
|
17
17
|
*
|
|
18
|
-
* Usage: node scripts/pin-workspace-deps.mjs [packageDir] [workspaceRoot]
|
|
18
|
+
* Usage: node .github/scripts/pin-workspace-deps.mjs [packageDir] [workspaceRoot]
|
|
19
19
|
* Both default to what the publish loop needs: the current directory, and its
|
|
20
20
|
* parent as the directory holding sibling packages.
|
|
21
21
|
*/
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* string back in keeps the committed diff to one line per bumped package, and
|
|
14
14
|
* keeps each file's original formatting.
|
|
15
15
|
*
|
|
16
|
-
* Usage: node scripts/restore-pinned-deps.mjs [packagesRoot...]
|
|
16
|
+
* Usage: node .github/scripts/restore-pinned-deps.mjs [packagesRoot...]
|
|
17
17
|
* Defaults to `packages`.
|
|
18
18
|
*/
|
|
19
19
|
import fs from 'node:fs';
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
*
|
|
14
14
|
* Cannot find module '<sibling>' or its corresponding type declarations.
|
|
15
15
|
*
|
|
16
|
-
* Usage: node scripts/workspace-build-order.mjs [rootDir]
|
|
16
|
+
* Usage: node .github/scripts/workspace-build-order.mjs [rootDir]
|
|
17
17
|
* rootDir defaults to `packages`. Prints one directory per line, with a
|
|
18
18
|
* trailing slash, e.g. `packages/my-lib/`.
|
|
19
19
|
*/
|
|
@@ -150,7 +150,7 @@ jobs:
|
|
|
150
150
|
unattempted_packages=""
|
|
151
151
|
auth_broken=""
|
|
152
152
|
|
|
153
|
-
build_order=$(node scripts/workspace-build-order.mjs)
|
|
153
|
+
build_order=$(node .github/scripts/workspace-build-order.mjs)
|
|
154
154
|
echo "📋 Build order:"
|
|
155
155
|
echo "$build_order" | sed 's/^/ /'
|
|
156
156
|
|
|
@@ -189,7 +189,7 @@ jobs:
|
|
|
189
189
|
# from the referenced local package; drop deps on local packages
|
|
190
190
|
# that are not published. Only committed back if the version is
|
|
191
191
|
# bumped.
|
|
192
|
-
node "$repo_root/scripts/pin-workspace-deps.mjs"
|
|
192
|
+
node "$repo_root/.github/scripts/pin-workspace-deps.mjs"
|
|
193
193
|
|
|
194
194
|
# Build before deciding anything: the tarball comparison below
|
|
195
195
|
# needs real dist output, and a package whose build fails is never
|
|
@@ -238,7 +238,7 @@ jobs:
|
|
|
238
238
|
# any version staged by an interrupted publish, and npm answers
|
|
239
239
|
# a PUT for one of those with E409 "Cannot publish over
|
|
240
240
|
# previously staged version".
|
|
241
|
-
next=$(node "$repo_root/scripts/next-free-version.mjs" "$name" "$version")
|
|
241
|
+
next=$(node "$repo_root/.github/scripts/next-free-version.mjs" "$name" "$version")
|
|
242
242
|
echo "🔼 $name content changed since $version — bumping to $next"
|
|
243
243
|
# --no-workspaces stops npm from doing workspace-aware
|
|
244
244
|
# processing over bun's symlinks, which trips
|
|
@@ -275,7 +275,7 @@ jobs:
|
|
|
275
275
|
exit 1
|
|
276
276
|
fi
|
|
277
277
|
|
|
278
|
-
next=$(node "$repo_root/scripts/next-free-version.mjs" "$name" "$version")
|
|
278
|
+
next=$(node "$repo_root/.github/scripts/next-free-version.mjs" "$name" "$version")
|
|
279
279
|
echo "↩ npm has $name@$version reserved — retrying as $next"
|
|
280
280
|
npm version "$next" --no-git-tag-version --no-workspaces
|
|
281
281
|
version="$next"
|
|
@@ -313,7 +313,7 @@ jobs:
|
|
|
313
313
|
# Bumps made during publish must land back in the repo so the next run
|
|
314
314
|
# sees them. The workspace:* pinning done for the tarballs must not —
|
|
315
315
|
# restore everything except the "version" field.
|
|
316
|
-
node scripts/restore-pinned-deps.mjs
|
|
316
|
+
node .github/scripts/restore-pinned-deps.mjs
|
|
317
317
|
git add '{{PACKAGES_GLOB}}/package.json'
|
|
318
318
|
git diff --staged --quiet && echo "No version changes to commit" && exit 0
|
|
319
319
|
git commit -m "chore: bump published package versions [skip ci]"
|