@hyperdx/cli 0.0.0 → 0.1.0-next.0
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/CHANGELOG.md +7 -0
- package/dist/{chunk-7UYWVS7D.js → chunk-VAVYH44V.js} +63 -11
- package/dist/chunk-VAVYH44V.js.map +1 -0
- package/dist/index.cjs +62 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1 -1
- package/dist/lib.cjs +62 -10
- package/dist/lib.cjs.map +1 -1
- package/dist/lib.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-7UYWVS7D.js.map +0 -1
package/CHANGELOG.md
ADDED
|
@@ -306,6 +306,60 @@ var require_brace_expansion = __commonJS({
|
|
|
306
306
|
}
|
|
307
307
|
});
|
|
308
308
|
|
|
309
|
+
// package.json
|
|
310
|
+
var require_package = __commonJS({
|
|
311
|
+
"package.json"(exports, module) {
|
|
312
|
+
module.exports = {
|
|
313
|
+
name: "@hyperdx/cli",
|
|
314
|
+
version: "0.1.0-next.0",
|
|
315
|
+
description: "HyperDX command line tool",
|
|
316
|
+
publishConfig: {
|
|
317
|
+
access: "public"
|
|
318
|
+
},
|
|
319
|
+
bin: "./dist/index.js",
|
|
320
|
+
author: "Warren <warren@users.noreply.github.com>",
|
|
321
|
+
license: "MIT",
|
|
322
|
+
main: "./dist/index.js",
|
|
323
|
+
module: "./dist/index.js",
|
|
324
|
+
types: "./dist/index.d.ts",
|
|
325
|
+
type: "module",
|
|
326
|
+
exports: {
|
|
327
|
+
".": {
|
|
328
|
+
require: "./dist/index.cjs",
|
|
329
|
+
import: "./dist/index.js",
|
|
330
|
+
types: "./dist/index.d.ts"
|
|
331
|
+
},
|
|
332
|
+
"./dist/lib": {
|
|
333
|
+
require: "./dist/lib.cjs",
|
|
334
|
+
import: "./dist/lib.js",
|
|
335
|
+
types: "./dist/lib.d.ts"
|
|
336
|
+
}
|
|
337
|
+
},
|
|
338
|
+
scripts: {
|
|
339
|
+
typegen: "tsup src/index.ts src/lib.ts --dts-only",
|
|
340
|
+
clean: "rimraf dist",
|
|
341
|
+
prebuild: "npm run clean",
|
|
342
|
+
build: "tsup"
|
|
343
|
+
},
|
|
344
|
+
installConfig: {
|
|
345
|
+
hoistingLimits: "workspaces"
|
|
346
|
+
},
|
|
347
|
+
devDependencies: {
|
|
348
|
+
"@types/node": "^18.15.5",
|
|
349
|
+
eslint: "^8.39.0",
|
|
350
|
+
"npm-run-all": "^4.1.5",
|
|
351
|
+
tsup: "6.6.2",
|
|
352
|
+
typescript: "^5.0.2"
|
|
353
|
+
},
|
|
354
|
+
dependencies: {
|
|
355
|
+
commander: "^10.0.0",
|
|
356
|
+
"cross-fetch": "^3.1.5",
|
|
357
|
+
glob: "^9.3.0"
|
|
358
|
+
}
|
|
359
|
+
};
|
|
360
|
+
}
|
|
361
|
+
});
|
|
362
|
+
|
|
309
363
|
// src/lib.ts
|
|
310
364
|
import { basename, join } from "path";
|
|
311
365
|
import { cwd } from "process";
|
|
@@ -7385,6 +7439,7 @@ var mjs_default = Object.assign(glob, {
|
|
|
7385
7439
|
});
|
|
7386
7440
|
|
|
7387
7441
|
// src/lib.ts
|
|
7442
|
+
var pj = require_package();
|
|
7388
7443
|
var uploadSourcemaps = (_0) => __async(void 0, [_0], function* ({
|
|
7389
7444
|
allowNoop,
|
|
7390
7445
|
apiKey,
|
|
@@ -7426,9 +7481,11 @@ var uploadSourcemaps = (_0) => __async(void 0, [_0], function* ({
|
|
|
7426
7481
|
console.info("Failed to upload source maps. Please see reason above.");
|
|
7427
7482
|
return;
|
|
7428
7483
|
}
|
|
7429
|
-
const
|
|
7430
|
-
|
|
7431
|
-
|
|
7484
|
+
const uploadKeys = fileList.map(({ name }) => ({
|
|
7485
|
+
basePath: basePath || "",
|
|
7486
|
+
fullName: name,
|
|
7487
|
+
releaseId
|
|
7488
|
+
}));
|
|
7432
7489
|
const urlRes = yield fetch(
|
|
7433
7490
|
join(backend, "api", "v1", "sourcemaps", "upload-presigned-urls"),
|
|
7434
7491
|
{
|
|
@@ -7438,7 +7495,8 @@ var uploadSourcemaps = (_0) => __async(void 0, [_0], function* ({
|
|
|
7438
7495
|
Authorization: `Bearer ${apiKey}`
|
|
7439
7496
|
},
|
|
7440
7497
|
body: JSON.stringify({
|
|
7441
|
-
|
|
7498
|
+
pkgVersion: pj.version,
|
|
7499
|
+
keys: uploadKeys
|
|
7442
7500
|
})
|
|
7443
7501
|
}
|
|
7444
7502
|
).then((response) => {
|
|
@@ -7508,12 +7566,6 @@ function getAllSourceMapFiles(_0, _1) {
|
|
|
7508
7566
|
return map;
|
|
7509
7567
|
});
|
|
7510
7568
|
}
|
|
7511
|
-
function getS3Key(teamId, basePath, fileName, releaseId) {
|
|
7512
|
-
if (releaseId === null || releaseId === void 0 || releaseId === "" || !releaseId) {
|
|
7513
|
-
releaseId = "unversioned";
|
|
7514
|
-
}
|
|
7515
|
-
return `${teamId}/${releaseId}/${basePath}${fileName}`;
|
|
7516
|
-
}
|
|
7517
7569
|
function uploadFile(filePath, uploadUrl, name) {
|
|
7518
7570
|
return __async(this, null, function* () {
|
|
7519
7571
|
const fileContent = readFileSync(filePath);
|
|
@@ -7525,4 +7577,4 @@ function uploadFile(filePath, uploadUrl, name) {
|
|
|
7525
7577
|
export {
|
|
7526
7578
|
uploadSourcemaps
|
|
7527
7579
|
};
|
|
7528
|
-
//# sourceMappingURL=chunk-
|
|
7580
|
+
//# sourceMappingURL=chunk-VAVYH44V.js.map
|