stacktape 3.0.9 → 3.0.10-beta.1
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/stacktape.js +33 -11
- package/package.json +1 -1
- package/sdk.d.ts +0 -20
- package/sdk.js +1 -3
- package/sdk.js.map +2 -2
package/bin/stacktape.js
CHANGED
|
@@ -6,7 +6,16 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
const { spawnSync, execSync } = require('node:child_process');
|
|
9
|
-
const {
|
|
9
|
+
const {
|
|
10
|
+
createWriteStream,
|
|
11
|
+
existsSync,
|
|
12
|
+
chmodSync,
|
|
13
|
+
mkdirSync,
|
|
14
|
+
accessSync,
|
|
15
|
+
constants,
|
|
16
|
+
unlinkSync,
|
|
17
|
+
readFileSync
|
|
18
|
+
} = require('node:fs');
|
|
10
19
|
const { get: httpsGet } = require('node:https');
|
|
11
20
|
const { platform, arch, homedir } = require('node:os');
|
|
12
21
|
const { join } = require('node:path');
|
|
@@ -230,25 +239,38 @@ function getManualInstallCommand(platformKey) {
|
|
|
230
239
|
return commands[platformKey] || 'See https://docs.stacktape.com for installation instructions';
|
|
231
240
|
}
|
|
232
241
|
|
|
233
|
-
function
|
|
242
|
+
function getGlobalBinaryPathIfVersionMatches() {
|
|
234
243
|
const binaryName = platform() === 'win32' ? 'stacktape.exe' : 'stacktape';
|
|
235
|
-
const
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
244
|
+
const globalDir = join(homedir(), '.stacktape', 'bin');
|
|
245
|
+
const globalBinaryPath = join(globalDir, binaryName);
|
|
246
|
+
const releaseDataPath = join(globalDir, 'release-data.json');
|
|
247
|
+
|
|
248
|
+
if (!existsSync(globalBinaryPath) || !existsSync(releaseDataPath)) {
|
|
249
|
+
return null;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
try {
|
|
253
|
+
const { version } = JSON.parse(readFileSync(releaseDataPath, 'utf8'));
|
|
254
|
+
if (version !== PACKAGE_VERSION) {
|
|
255
|
+
return null;
|
|
242
256
|
}
|
|
257
|
+
} catch {
|
|
258
|
+
return null;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
try {
|
|
262
|
+
accessSync(globalBinaryPath, constants.X_OK);
|
|
263
|
+
return globalBinaryPath;
|
|
264
|
+
} catch {
|
|
265
|
+
return globalBinaryPath;
|
|
243
266
|
}
|
|
244
|
-
return null;
|
|
245
267
|
}
|
|
246
268
|
|
|
247
269
|
async function main() {
|
|
248
270
|
try {
|
|
249
271
|
const args = process.argv.slice(2);
|
|
250
272
|
|
|
251
|
-
const globalBinaryPath =
|
|
273
|
+
const globalBinaryPath = getGlobalBinaryPathIfVersionMatches();
|
|
252
274
|
if (globalBinaryPath) {
|
|
253
275
|
const result = spawnSync(globalBinaryPath, args, {
|
|
254
276
|
stdio: 'inherit',
|
package/package.json
CHANGED
package/sdk.d.ts
CHANGED
|
@@ -25808,16 +25808,6 @@ declare class Stacktape {
|
|
|
25808
25808
|
*/
|
|
25809
25809
|
noCache?: boolean,
|
|
25810
25810
|
/**
|
|
25811
|
-
* #### Disable Docker Remote Cache
|
|
25812
|
-
*
|
|
25813
|
-
* ---
|
|
25814
|
-
*
|
|
25815
|
-
* Disables Docker layer caching using ECR as remote cache storage.
|
|
25816
|
-
* By default, remote caching is enabled to speed up Docker builds by reusing layers.
|
|
25817
|
-
* Set to `true` to disable remote caching.
|
|
25818
|
-
*/
|
|
25819
|
-
disableDockerRemoteCache?: boolean,
|
|
25820
|
-
/**
|
|
25821
25811
|
* #### Disable Auto-Rollback
|
|
25822
25812
|
*
|
|
25823
25813
|
* ---
|
|
@@ -26081,16 +26071,6 @@ declare class Stacktape {
|
|
|
26081
26071
|
*/
|
|
26082
26072
|
noCache?: boolean,
|
|
26083
26073
|
/**
|
|
26084
|
-
* #### Disable Docker Remote Cache
|
|
26085
|
-
*
|
|
26086
|
-
* ---
|
|
26087
|
-
*
|
|
26088
|
-
* Disables Docker layer caching using ECR as remote cache storage.
|
|
26089
|
-
* By default, remote caching is enabled to speed up Docker builds by reusing layers.
|
|
26090
|
-
* Set to `true` to disable remote caching.
|
|
26091
|
-
*/
|
|
26092
|
-
disableDockerRemoteCache?: boolean,
|
|
26093
|
-
/**
|
|
26094
26074
|
* #### Disable Auto-Rollback
|
|
26095
26075
|
*
|
|
26096
26076
|
* ---
|
package/sdk.js
CHANGED
|
@@ -14183,9 +14183,7 @@ var allowedSdkArgs = {
|
|
|
14183
14183
|
};
|
|
14184
14184
|
|
|
14185
14185
|
// src/config/random.ts
|
|
14186
|
-
var
|
|
14187
|
-
var IS_DEV_BIN = process.env.STP_DEV_BIN_MODE === "true";
|
|
14188
|
-
var IS_DEV = IS_DEV_NATIVE || IS_DEV_BIN;
|
|
14186
|
+
var IS_DEV = process.env.STP_DEV_MODE === "true";
|
|
14189
14187
|
var SCHEMAS_BUCKET_NAME = process.env.SCHEMAS_BUCKET_NAME || "internal-services-production-schemasbucket-eb6fca19";
|
|
14190
14188
|
var AI_DOCS_BUCKET_NAME = process.env.AI_DOCS_BUCKET_NAME || "console-app-dev-mcpdocsbucket-743a732";
|
|
14191
14189
|
var INSTALL_SCRIPTS_BUCKET_NAME = process.env.INSTALL_SCRIPTS_BUCKET_NAME || "internal-services-production-installscriptsbucket-eb6fca19";
|