@cloudops-tools/cli 0.1.0 → 0.1.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/cloudops-tools.js +1 -1
- package/package.json +9 -10
- package/scripts/install-native.js +6 -3
package/bin/cloudops-tools.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
+
import { spawnSync } from "node:child_process";
|
|
3
4
|
import { existsSync } from "node:fs";
|
|
4
5
|
import { dirname, resolve } from "node:path";
|
|
5
6
|
import process from "node:process";
|
|
6
7
|
import { fileURLToPath } from "node:url";
|
|
7
|
-
import { spawnSync } from "node:child_process";
|
|
8
8
|
|
|
9
9
|
const here = dirname(fileURLToPath(import.meta.url));
|
|
10
10
|
const binaryName = process.platform === "win32" ? "cloudops-tools.exe" : "cloudops-tools";
|
package/package.json
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudops-tools/cli",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"type": "module",
|
|
3
|
+
"version": "0.1.1",
|
|
5
4
|
"bin": {
|
|
6
5
|
"cloudops-tools": "./bin/cloudops-tools.js"
|
|
7
6
|
},
|
|
@@ -9,6 +8,7 @@
|
|
|
9
8
|
"bin",
|
|
10
9
|
"scripts"
|
|
11
10
|
],
|
|
11
|
+
"type": "module",
|
|
12
12
|
"module": "./src/app.ts",
|
|
13
13
|
"scripts": {
|
|
14
14
|
"build:all": "bun run check && bun run build:windows-x64 && bun run build:linux-x64 && bun run build:macOS-arm",
|
|
@@ -21,26 +21,25 @@
|
|
|
21
21
|
"postinstall": "node ./scripts/install-native.js",
|
|
22
22
|
"typecheck": "tsgo --noEmit"
|
|
23
23
|
},
|
|
24
|
-
"dependencies": {
|
|
24
|
+
"dependencies": {},
|
|
25
|
+
"devDependencies": {
|
|
25
26
|
"@cloudops-tools/sdk": "workspace:*",
|
|
26
27
|
"@effect/cli": "catalog:effect",
|
|
27
28
|
"@effect/platform": "catalog:effect",
|
|
28
29
|
"@effect/platform-bun": "catalog:effect",
|
|
29
|
-
"effect": "catalog:effect",
|
|
30
|
-
"exceljs": "catalog:utilities",
|
|
31
|
-
"json2md": "catalog:utilities",
|
|
32
|
-
"otpauth": "catalog:utilities",
|
|
33
|
-
"picocolors": "1.1.1"
|
|
34
|
-
},
|
|
35
|
-
"devDependencies": {
|
|
36
30
|
"@types/bun": "catalog:types",
|
|
37
31
|
"@types/json2md": "catalog:types",
|
|
38
32
|
"@types/node": "catalog:types",
|
|
39
33
|
"@types/progress": "catalog:types",
|
|
40
34
|
"@typescript/native-preview": "catalog:build",
|
|
35
|
+
"effect": "catalog:effect",
|
|
36
|
+
"exceljs": "catalog:utilities",
|
|
37
|
+
"json2md": "catalog:utilities",
|
|
38
|
+
"otpauth": "catalog:utilities",
|
|
41
39
|
"oxfmt": "catalog:build",
|
|
42
40
|
"oxlint": "catalog:build",
|
|
43
41
|
"oxlint-tsgolint": "catalog:build",
|
|
42
|
+
"picocolors": "1.1.1",
|
|
44
43
|
"typescript": "catalog:build"
|
|
45
44
|
}
|
|
46
45
|
}
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
/* eslint-disable no-console */
|
|
3
3
|
|
|
4
4
|
import { createWriteStream, existsSync, mkdirSync, readFileSync, rmSync, chmodSync } from "node:fs";
|
|
5
|
+
import { get } from "node:https";
|
|
5
6
|
import { dirname, resolve } from "node:path";
|
|
6
|
-
import { fileURLToPath } from "node:url";
|
|
7
7
|
import process from "node:process";
|
|
8
8
|
import { pipeline } from "node:stream/promises";
|
|
9
|
-
import {
|
|
9
|
+
import { fileURLToPath } from "node:url";
|
|
10
10
|
|
|
11
11
|
const here = dirname(fileURLToPath(import.meta.url));
|
|
12
12
|
const cliDir = resolve(here, "..");
|
|
@@ -20,7 +20,10 @@ const shouldSkipInstall = () => {
|
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
// Do not auto-download when working from the monorepo checkout.
|
|
23
|
-
if (
|
|
23
|
+
if (
|
|
24
|
+
existsSync(resolve(repoRoot, ".git")) &&
|
|
25
|
+
process.env.CLOUDOPS_TOOLS_FORCE_NATIVE_INSTALL !== "1"
|
|
26
|
+
) {
|
|
24
27
|
return true;
|
|
25
28
|
}
|
|
26
29
|
|