@stacksjs/buddy 0.70.120 → 0.70.122

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.
@@ -75,6 +75,43 @@ console.log('[${name}] popup')
75
75
  log.success(`Packaged ${config.name} (${target}) \u2192 ${out}`);
76
76
  }
77
77
  });
78
+ buddy.command("extension:chrome:status", "Fetch the Chrome Web Store item status").option("--service-account-path <path>", "Google service-account JSON key path").option("--access-token <token>", "Short-lived Chrome Web Store OAuth access token").action(async (options) => {
79
+ const { ChromeWebStoreClient } = await import("@stacksjs/browser-extension"), { config } = await load();
80
+ if (!config.chromeWebStore)
81
+ throw Error("Chrome status needs chromeWebStore.publisherId and chromeWebStore.itemId in config/extension.ts");
82
+ const status = await new ChromeWebStoreClient(options).fetchStatus(config.chromeWebStore);
83
+ log.info(`Chrome Web Store item ${status.itemId}`);
84
+ log.info(`published: ${status.publishedItemRevisionStatus?.state ?? "none"}`);
85
+ log.info(`submitted: ${status.submittedItemRevisionStatus?.state ?? "none"}`);
86
+ if (status.warned)
87
+ log.warn("Chrome has warned this item for a policy violation.");
88
+ if (status.takenDown)
89
+ log.error("Chrome has taken this item down for a policy violation.");
90
+ });
91
+ buddy.command("extension:chrome:publish", "Build, upload, and submit the Chrome extension through Web Store API v2").option("--version <version>", "Override the extension version (defaults to package.json)").option("--service-account-path <path>", "Google service-account JSON key path").option("--access-token <token>", "Short-lived Chrome Web Store OAuth access token").option("--upload-only", "Upload without submitting the item for review").option("--allow-warnings", "Submit even when Chrome reports validation warnings").action(async (options) => {
92
+ const { publishChromeExtension } = await import("@stacksjs/browser-extension"), { config, version } = await load(), result = await publishChromeExtension(config, {
93
+ version: options.version ?? version,
94
+ serviceAccountPath: options.serviceAccountPath,
95
+ accessToken: options.accessToken,
96
+ uploadOnly: Boolean(options.uploadOnly),
97
+ blockOnWarnings: !options.allowWarnings
98
+ });
99
+ log.success(`Uploaded Chrome package ${result.packagePath} (${result.upload.crxVersion ?? "processing complete"})`);
100
+ if (result.publish)
101
+ log.success(`Submitted Chrome Web Store item ${result.publish.itemId}: ${result.publish.state}`);
102
+ });
103
+ buddy.command("extension:firefox:publish", "Build and submit the Firefox extension through Mozilla Add-ons").option("--version <version>", "Override the extension version (defaults to package.json)").option("--api-key <issuer>", "AMO JWT issuer").option("--api-secret <secret>", "AMO JWT secret").option("--source-code <path>", "Human-readable source archive for AMO review").option("--approval-timeout <milliseconds>", "How long to wait for human approval (default 0)").action(async (options) => {
104
+ const { publishFirefoxExtension } = await import("@stacksjs/browser-extension"), { config, version } = await load(), result = await publishFirefoxExtension(config, {
105
+ version: options.version ?? version,
106
+ issuer: options.apiKey,
107
+ secret: options.apiSecret,
108
+ sourceCodePath: options.sourceCode,
109
+ approvalTimeout: options.approvalTimeout === void 0 ? void 0 : Number(options.approvalTimeout)
110
+ });
111
+ log.success(`Submitted Firefox extension (${result.channel}) \u2192 ${result.artifactsDir}`);
112
+ if (result.artifacts.length)
113
+ log.info(`new artifacts: ${result.artifacts.join(", ")}`);
114
+ });
78
115
  buddy.command("extension:safari:provision", "Register Safari Bundle IDs and check the App Store Connect app record").option("--api-key-id <id>", "App Store Connect API key ID").option("--api-issuer-id <id>", "App Store Connect API issuer ID").option("--api-key-path <path>", "Path to the App Store Connect AuthKey_*.p8 file").option("--check", "Report missing resources without creating Bundle IDs").action(async (options) => {
79
116
  const { provisionSafariApp } = await import("@stacksjs/browser-extension"), { config } = await load(), result = await provisionSafariApp(config, {
80
117
  keyId: options.apiKeyId,
@@ -26,6 +26,9 @@ const commandRegistry = {
26
26
  "extension:init": { path: "./commands/extension.js", exportName: "extension" },
27
27
  "extension:build": { path: "./commands/extension.js", exportName: "extension" },
28
28
  "extension:package": { path: "./commands/extension.js", exportName: "extension" },
29
+ "extension:chrome:publish": { path: "./commands/extension.js", exportName: "extension" },
30
+ "extension:chrome:status": { path: "./commands/extension.js", exportName: "extension" },
31
+ "extension:firefox:publish": { path: "./commands/extension.js", exportName: "extension" },
29
32
  "extension:safari:init": { path: "./commands/extension.js", exportName: "extension" },
30
33
  "extension:safari:provision": { path: "./commands/extension.js", exportName: "extension" },
31
34
  "extension:safari:app": { path: "./commands/extension.js", exportName: "extension" },
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@stacksjs/buddy",
3
3
  "type": "module",
4
4
  "sideEffects": false,
5
- "version": "0.70.120",
5
+ "version": "0.70.122",
6
6
  "description": "Meet Buddy. The Stacks runtime.",
7
7
  "author": "Chris Breuer",
8
8
  "contributors": [
@@ -92,51 +92,51 @@
92
92
  "prepublishOnly": "bun run build"
93
93
  },
94
94
  "dependencies": {
95
- "@stacksjs/actions": "^0.70.120",
96
- "@stacksjs/ai": "^0.70.120",
97
- "@stacksjs/alias": "^0.70.120",
98
- "@stacksjs/arrays": "^0.70.120",
99
- "@stacksjs/auth": "^0.70.120",
100
- "@stacksjs/build": "^0.70.120",
101
- "@stacksjs/cache": "^0.70.120",
102
- "@stacksjs/cli": "^0.70.120",
95
+ "@stacksjs/actions": "^0.70.122",
96
+ "@stacksjs/ai": "^0.70.122",
97
+ "@stacksjs/alias": "^0.70.122",
98
+ "@stacksjs/arrays": "^0.70.122",
99
+ "@stacksjs/auth": "^0.70.122",
100
+ "@stacksjs/build": "^0.70.122",
101
+ "@stacksjs/cache": "^0.70.122",
102
+ "@stacksjs/cli": "^0.70.122",
103
103
  "@stacksjs/clapp": "^0.2.10",
104
- "@stacksjs/cloud": "^0.70.120",
105
- "@stacksjs/collections": "^0.70.120",
106
- "@stacksjs/config": "^0.70.120",
107
- "@stacksjs/database": "^0.70.120",
108
- "@stacksjs/desktop": "^0.70.120",
109
- "@stacksjs/dns": "^0.70.120",
110
- "@stacksjs/email": "^0.70.120",
111
- "@stacksjs/enums": "^0.70.120",
112
- "@stacksjs/error-handling": "^0.70.120",
113
- "@stacksjs/events": "^0.70.120",
114
- "@stacksjs/git": "^0.70.120",
104
+ "@stacksjs/cloud": "^0.70.122",
105
+ "@stacksjs/collections": "^0.70.122",
106
+ "@stacksjs/config": "^0.70.122",
107
+ "@stacksjs/database": "^0.70.122",
108
+ "@stacksjs/desktop": "^0.70.122",
109
+ "@stacksjs/dns": "^0.70.122",
110
+ "@stacksjs/email": "^0.70.122",
111
+ "@stacksjs/enums": "^0.70.122",
112
+ "@stacksjs/error-handling": "^0.70.122",
113
+ "@stacksjs/events": "^0.70.122",
114
+ "@stacksjs/git": "^0.70.122",
115
115
  "@stacksjs/gitit": "^0.2.5",
116
- "@stacksjs/health": "^0.70.120",
116
+ "@stacksjs/health": "^0.70.122",
117
117
  "@stacksjs/dnsx": "^0.2.3",
118
118
  "@stacksjs/httx": "^0.1.10",
119
- "@stacksjs/lint": "^0.70.120",
120
- "@stacksjs/logging": "^0.70.120",
121
- "@stacksjs/notifications": "^0.70.120",
122
- "@stacksjs/objects": "^0.70.120",
123
- "@stacksjs/orm": "^0.70.120",
124
- "@stacksjs/path": "^0.70.120",
125
- "@stacksjs/payments": "^0.70.120",
126
- "@stacksjs/realtime": "^0.70.120",
127
- "@stacksjs/router": "^0.70.120",
119
+ "@stacksjs/lint": "^0.70.122",
120
+ "@stacksjs/logging": "^0.70.122",
121
+ "@stacksjs/notifications": "^0.70.122",
122
+ "@stacksjs/objects": "^0.70.122",
123
+ "@stacksjs/orm": "^0.70.122",
124
+ "@stacksjs/path": "^0.70.122",
125
+ "@stacksjs/payments": "^0.70.122",
126
+ "@stacksjs/realtime": "^0.70.122",
127
+ "@stacksjs/router": "^0.70.122",
128
128
  "@stacksjs/rpx": "^0.11.29",
129
- "@stacksjs/search-engine": "^0.70.120",
130
- "@stacksjs/security": "^0.70.120",
131
- "@stacksjs/server": "^0.70.120",
132
- "@stacksjs/storage": "^0.70.120",
133
- "@stacksjs/strings": "^0.70.120",
134
- "@stacksjs/testing": "^0.70.120",
135
- "@stacksjs/tunnel": "^0.70.120",
136
- "@stacksjs/types": "^0.70.120",
137
- "@stacksjs/ui": "^0.70.120",
138
- "@stacksjs/utils": "^0.70.120",
139
- "@stacksjs/validation": "^0.70.120",
129
+ "@stacksjs/search-engine": "^0.70.122",
130
+ "@stacksjs/security": "^0.70.122",
131
+ "@stacksjs/server": "^0.70.122",
132
+ "@stacksjs/storage": "^0.70.122",
133
+ "@stacksjs/strings": "^0.70.122",
134
+ "@stacksjs/testing": "^0.70.122",
135
+ "@stacksjs/tunnel": "^0.70.122",
136
+ "@stacksjs/types": "^0.70.122",
137
+ "@stacksjs/ui": "^0.70.122",
138
+ "@stacksjs/utils": "^0.70.122",
139
+ "@stacksjs/validation": "^0.70.122",
140
140
  "@stacksjs/ts-cloud": "^0.7.36"
141
141
  },
142
142
  "devDependencies": {