@airig/cli 0.0.4 → 0.0.5

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/README.md CHANGED
@@ -58,8 +58,28 @@ Package releases are separate from Setup Releases. `airig publish [tag]` creates
58
58
  4. Run `airig publish` to upload `ai.zip` to an immutable GitHub Setup Release.
59
59
  5. Share `airig add yourname/repo`.
60
60
 
61
+ For AI Setup repositories, use [`bumpp`](https://github.com/antfu-collective/bumpp)
62
+ to create and push release tags from a package script:
63
+
64
+ ```json
65
+ {
66
+ "scripts": {
67
+ "release": "bumpp"
68
+ }
69
+ }
70
+ ```
71
+
72
+ To publish Setup Releases from your AI Setup repository with GitHub Actions, copy
73
+ `resources/templates/publish.yml` to `.github/workflows/publish.yml` in that
74
+ repository. The workflow publishes when `bumpp` pushes a `v*` tag and expects an
75
+ `AIRIG_PUBLISH_TOKEN` repository secret. Create that secret from a fine-grained
76
+ GitHub PAT scoped only to the Setup Release repository with:
77
+
78
+ - `Contents`: Read and write
79
+ - `Administration`: Read-only
80
+
61
81
  ## Requirements
62
82
 
63
83
  - Node.js `24.11.0` or newer in the Node 24 release line.
64
84
  - GitHub immutable releases enabled for repositories that publish Setup Releases.
65
- - `GITHUB_TOKEN` with repository write access when running `publish`.
85
+ - `GITHUB_TOKEN` when running `publish`. For local use or custom GitHub Actions workflows, use a fine-grained GitHub PAT scoped to the Setup Release repository with `Contents` read/write access to create releases and `Administration` read-only access so `airig publish` can verify immutable releases are enabled before publishing.
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@ import { execSync, spawn } from "node:child_process";
4
4
  import { cp, lstat, mkdir, mkdtemp, readFile, readdir, readlink, rm, symlink, unlink, writeFile } from "node:fs/promises";
5
5
  import path, { join } from "node:path";
6
6
  import { parseEnv } from "node:util";
7
- import archiver from "archiver";
7
+ import { ZipArchive } from "archiver";
8
8
  import { createWriteStream, existsSync, mkdirSync, readFileSync, writeFileSync } from "node:fs";
9
9
  import { Octokit } from "@octokit/rest";
10
10
  import { checkbox } from "@inquirer/prompts";
@@ -15,7 +15,7 @@ import { fileURLToPath } from "node:url";
15
15
  function create(sourceDir, outputPath) {
16
16
  return new Promise((resolve, reject) => {
17
17
  const output = createWriteStream(outputPath);
18
- const archive = archiver("zip", { zlib: { level: 9 } });
18
+ const archive = new ZipArchive({ zlib: { level: 9 } });
19
19
  const sourceBaseName = path.basename(sourceDir);
20
20
  output.on("close", resolve);
21
21
  archive.on("error", reject);
@@ -1052,7 +1052,7 @@ function formatUpdateMessage(opts) {
1052
1052
  }
1053
1053
  //#endregion
1054
1054
  //#region src/index.ts
1055
- const program = new Command("airig").description("Manage project-scoped AI Setup artifacts");
1055
+ const program = new Command("airig").description("Manage project-scoped AI Setup artifacts").version("0.0.5");
1056
1056
  program.addCommand(publishCommand);
1057
1057
  program.addCommand(addCommand);
1058
1058
  program.addCommand(updateCommand);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@airig/cli",
3
- "version": "0.0.4",
3
+ "version": "0.0.5",
4
4
  "description": "Distribute and manage AI setups across providers",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -38,12 +38,12 @@
38
38
  "dependencies": {
39
39
  "@inquirer/prompts": "^7.5.2",
40
40
  "@octokit/rest": "^21.1.1",
41
- "archiver": "^7.0.1",
41
+ "archiver": "^8.0.0",
42
42
  "commander": "^14.0.0",
43
43
  "extract-zip": "^2.0.1"
44
44
  },
45
45
  "devDependencies": {
46
- "@types/archiver": "^6.0.3",
46
+ "@types/archiver": "^8.0.0",
47
47
  "@types/node": "^22.15.21",
48
48
  "bumpp": "^11.1.0",
49
49
  "tsdown": "^0.12.6",