sn-typescript-util 1.5.12 → 1.5.14

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.
@@ -7,7 +7,9 @@
7
7
  "Bash(bunx tsc:*)",
8
8
  "Bash(git show:*)",
9
9
  "Bash(npx tsc:*)",
10
- "Bash(timeout 5 npx tsc:*)"
10
+ "Bash(timeout 5 npx tsc:*)",
11
+ "Bash(bun remove:*)",
12
+ "Bash(snts:*)"
11
13
  ]
12
14
  }
13
15
  }
package/bun.lock CHANGED
@@ -7,16 +7,16 @@
7
7
  "@clack/prompts": "^0.10.1",
8
8
  "colorette": "^2.0.20",
9
9
  "commander": "^13.1.0",
10
- "execa": "^9.5.3",
11
- "typescript": "^5.8.3",
10
+ "execa": "^9.6.1",
11
+ "typescript": "^5.9.3",
12
12
  },
13
13
  "devDependencies": {
14
- "@eslint/js": "^9.26.0",
14
+ "@eslint/js": "^9.39.2",
15
+ "@types/bun": "^1.3.8",
15
16
  "@types/commander": "^2.12.5",
16
- "bun-types": "^1.2.12",
17
- "eslint": "^9.26.0",
18
- "prettier": "^3.5.3",
19
- "typescript-eslint": "^8.32.0",
17
+ "eslint": "^9.39.2",
18
+ "prettier": "^3.8.1",
19
+ "typescript-eslint": "^8.54.0",
20
20
  },
21
21
  },
22
22
  },
@@ -55,6 +55,8 @@
55
55
 
56
56
  "@sindresorhus/merge-streams": ["@sindresorhus/merge-streams@4.0.0", "", {}, "sha512-tlqY9xq5ukxTUZBmoOp+m61cqwQD5pHJtFY3Mn8CA8ps6yghLH/Hw8UPdqg4OLmFW3IFlcXnQNmo/dh8HzXYIQ=="],
57
57
 
58
+ "@types/bun": ["@types/bun@1.3.8", "", { "dependencies": { "bun-types": "1.3.8" } }, "sha512-3LvWJ2q5GerAXYxO2mffLTqOzEu5qnhEAlh48Vnu8WQfnmSwbgagjGZV6BoHKJztENYEDn6QmVd949W4uESRJA=="],
59
+
58
60
  "@types/commander": ["@types/commander@2.12.5", "", { "dependencies": { "commander": "*" } }, "sha512-YXGZ/rz+s57VbzcvEV9fUoXeJlBt5HaKu5iUheiIWNsJs23bz6AnRuRiZBRVBLYyPnixNvVnuzM5pSaxr8Yp/g=="],
59
61
 
60
62
  "@types/estree": ["@types/estree@1.0.6", "", {}, "sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw=="],
@@ -97,7 +99,7 @@
97
99
 
98
100
  "brace-expansion": ["brace-expansion@1.1.11", "", { "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" } }, "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA=="],
99
101
 
100
- "bun-types": ["bun-types@1.3.7", "", { "dependencies": { "@types/node": "*" } }, "sha512-qyschsA03Qz+gou+apt6HNl6HnI+sJJLL4wLDke4iugsE6584CMupOtTY1n+2YC9nGVrEKUlTs99jjRLKgWnjQ=="],
102
+ "bun-types": ["bun-types@1.3.8", "", { "dependencies": { "@types/node": "*" } }, "sha512-fL99nxdOWvV4LqjmC+8Q9kW3M4QTtTR1eePs94v5ctGqU8OeceWrSUaRw3JYb7tU3FkMIAjkueehrHPPPGKi5Q=="],
101
103
 
102
104
  "callsites": ["callsites@3.1.0", "", {}, "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ=="],
103
105
 
package/eslint.config.js CHANGED
@@ -3,10 +3,10 @@
3
3
  import eslint from '@eslint/js';
4
4
  import tseslint from 'typescript-eslint';
5
5
 
6
- export default tseslint.config(
6
+ export default [
7
7
  eslint.configs.recommended,
8
8
  ...tseslint.configs.recommended,
9
9
  {
10
10
  ignores: ['node_modules', 'tmp']
11
11
  }
12
- );
12
+ ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sn-typescript-util",
3
- "version": "1.5.12",
3
+ "version": "1.5.14",
4
4
  "description": "A TypeScript utility for ServiceNow developers using VS Code",
5
5
  "bin": {
6
6
  "snts": "bin/snts.js"
@@ -32,8 +32,8 @@
32
32
  },
33
33
  "devDependencies": {
34
34
  "@eslint/js": "^9.39.2",
35
+ "@types/bun": "^1.3.8",
35
36
  "@types/commander": "^2.12.5",
36
- "bun-types": "^1.3.7",
37
37
  "eslint": "^9.39.2",
38
38
  "prettier": "^3.8.1",
39
39
  "typescript-eslint": "^8.54.0"
@@ -16,8 +16,8 @@ async function cancelOperation() {
16
16
  process.exit(0);
17
17
  }
18
18
 
19
- async function confirmVersion(version: string) {
20
- return await confirm({
19
+ function confirmVersion(version: string) {
20
+ return confirm({
21
21
  message: `Bump to ${version}?`
22
22
  });
23
23
  }
@@ -54,11 +54,11 @@ function getFilePath(file: string, dir: string): string {
54
54
  return path.join(projectRoot, dir, file);
55
55
  }
56
56
 
57
- async function getPackageInfo(): Promise<Metadata & { version: string }> {
57
+ function getPackageInfo(): Metadata & { version: string } {
58
58
  return JSON.parse(readFileSync(getFilePath('package.json', '.')).toString());
59
59
  }
60
60
 
61
- async function getReleaseTypes(): Promise<symbol | VersionType> {
61
+ function getReleaseTypes(): Promise<symbol | VersionType> {
62
62
  return select({
63
63
  message: 'Please pick a release type.',
64
64
  options: getOptions()
@@ -73,9 +73,8 @@ function getOptions(): Version[] {
73
73
  ];
74
74
  }
75
75
 
76
- async function getVersion() {
77
- const file = await getPackageInfo();
78
- return `v${file.version}`;
76
+ function getVersion() {
77
+ return `v${getPackageInfo().version}`;
79
78
  }
80
79
 
81
80
  function isNotSymbol(value: unknown): value is boolean {
@@ -93,7 +92,7 @@ function isVersionType(value: unknown): value is VersionType {
93
92
  cancelOperation();
94
93
  return;
95
94
  }
96
- const version = (await bumpVersion(releaseType)) && (await getVersion());
95
+ const version = (await bumpVersion(releaseType)) && getVersion();
97
96
  const shouldContinue = await confirmVersion(version);
98
97
  return await doOperation(shouldContinue, version);
99
98
  })();
package/src/snts.ts CHANGED
@@ -223,7 +223,7 @@ function getVersion() {
223
223
  return info.version;
224
224
  }
225
225
 
226
- function getWorkspace() {
226
+ function getWorkspace(): Workspace {
227
227
  return JSON.parse(readFileSync('./system/sn-workspace.json').toString());
228
228
  }
229
229