@procore/hammer-lib-tsup 0.5.1 → 0.6.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 +26 -0
- package/dist/index.d.mts +5 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.js +14 -4
- package/dist/index.mjs +11 -3
- package/package.json +21 -19
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,31 @@
|
|
|
1
1
|
# @procore/hammer-lib-tsup
|
|
2
2
|
|
|
3
|
+
## 0.6.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 9407067: Add new general command `init` for hammer and all plugins
|
|
8
|
+
- a3dadc6: Update engine.node version with actual supported node versions
|
|
9
|
+
- f4d2605: Implemented init function for lib-tsup plugin to successfully initialize the project
|
|
10
|
+
- bdf3901: Upgrades dependencies.
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies [2aa7e7b]
|
|
15
|
+
- Updated dependencies [9407067]
|
|
16
|
+
- Updated dependencies [f4d2605]
|
|
17
|
+
- Updated dependencies [1f1d590]
|
|
18
|
+
- @procore/hammer-types@0.5.0
|
|
19
|
+
- @procore/hammer-utils@0.1.0
|
|
20
|
+
|
|
21
|
+
## 0.5.2
|
|
22
|
+
|
|
23
|
+
### Patch Changes
|
|
24
|
+
|
|
25
|
+
- 40b7081: Updated some dependencies.
|
|
26
|
+
- Updated dependencies [007e20f]
|
|
27
|
+
- @procore/hammer-types@0.4.0
|
|
28
|
+
|
|
3
29
|
## 0.5.1
|
|
4
30
|
|
|
5
31
|
### Patch Changes
|
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import * as _procore_hammer_types from '@procore/hammer-types';
|
|
2
2
|
|
|
3
|
+
declare const init: (rootDir: string, config: _procore_hammer_types.HammerConfig, options: {
|
|
4
|
+
force?: boolean;
|
|
5
|
+
}) => Promise<void>;
|
|
3
6
|
declare const build: (rootDir: string, config: _procore_hammer_types.HammerConfig, options: {
|
|
4
7
|
analyze: boolean;
|
|
5
8
|
}) => Promise<void>;
|
|
@@ -10,5 +13,6 @@ declare const inspect: (rootDir: string, config: _procore_hammer_types.HammerCon
|
|
|
10
13
|
declare const start: (rootDir: string, config: _procore_hammer_types.HammerConfig, options: {
|
|
11
14
|
analyze: boolean;
|
|
12
15
|
}) => Promise<void>;
|
|
16
|
+
declare const validate: (rootDir: string, config: _procore_hammer_types.HammerConfig) => Promise<void>;
|
|
13
17
|
|
|
14
|
-
export { build, clean, inspect, start };
|
|
18
|
+
export { build, clean, init, inspect, start, validate };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import * as _procore_hammer_types from '@procore/hammer-types';
|
|
2
2
|
|
|
3
|
+
declare const init: (rootDir: string, config: _procore_hammer_types.HammerConfig, options: {
|
|
4
|
+
force?: boolean;
|
|
5
|
+
}) => Promise<void>;
|
|
3
6
|
declare const build: (rootDir: string, config: _procore_hammer_types.HammerConfig, options: {
|
|
4
7
|
analyze: boolean;
|
|
5
8
|
}) => Promise<void>;
|
|
@@ -10,5 +13,6 @@ declare const inspect: (rootDir: string, config: _procore_hammer_types.HammerCon
|
|
|
10
13
|
declare const start: (rootDir: string, config: _procore_hammer_types.HammerConfig, options: {
|
|
11
14
|
analyze: boolean;
|
|
12
15
|
}) => Promise<void>;
|
|
16
|
+
declare const validate: (rootDir: string, config: _procore_hammer_types.HammerConfig) => Promise<void>;
|
|
13
17
|
|
|
14
|
-
export { build, clean, inspect, start };
|
|
18
|
+
export { build, clean, init, inspect, start, validate };
|
package/dist/index.js
CHANGED
|
@@ -32,8 +32,10 @@ var src_exports = {};
|
|
|
32
32
|
__export(src_exports, {
|
|
33
33
|
build: () => build,
|
|
34
34
|
clean: () => clean,
|
|
35
|
+
init: () => init,
|
|
35
36
|
inspect: () => inspect,
|
|
36
|
-
start: () => start
|
|
37
|
+
start: () => start,
|
|
38
|
+
validate: () => validate
|
|
37
39
|
});
|
|
38
40
|
module.exports = __toCommonJS(src_exports);
|
|
39
41
|
var import_node_process = __toESM(require("process"));
|
|
@@ -96,7 +98,7 @@ function toHighlightedString(input) {
|
|
|
96
98
|
const inputAsString = JSON.stringify(
|
|
97
99
|
input,
|
|
98
100
|
function(_key, value) {
|
|
99
|
-
return typeof value === "function" ? value.
|
|
101
|
+
return typeof value === "function" ? value.name : value;
|
|
100
102
|
},
|
|
101
103
|
2
|
|
102
104
|
);
|
|
@@ -146,7 +148,11 @@ async function performBuild(buildOptions) {
|
|
|
146
148
|
}
|
|
147
149
|
|
|
148
150
|
// src/index.ts
|
|
149
|
-
var
|
|
151
|
+
var import_hammer_utils = require("@procore/hammer-utils");
|
|
152
|
+
var { init, build, clean, inspect, start, validate } = {
|
|
153
|
+
init: async function init2(rootDir, config, options) {
|
|
154
|
+
await (0, import_hammer_utils.updatePackageJsonFromTemplate)(rootDir, options.force);
|
|
155
|
+
},
|
|
150
156
|
build: async function build2(rootDir, config, options) {
|
|
151
157
|
const pluginOptions = { ...options, config };
|
|
152
158
|
const buildOptions = await createBuildOptions(base_configs_default, pluginOptions);
|
|
@@ -169,12 +175,16 @@ ${highlightedConfig}
|
|
|
169
175
|
const pluginOptions = { ...options, config, watch: true };
|
|
170
176
|
const buildOptions = await createBuildOptions(base_configs_default, pluginOptions);
|
|
171
177
|
await performBuild(buildOptions);
|
|
178
|
+
},
|
|
179
|
+
validate: async function validate2() {
|
|
172
180
|
}
|
|
173
181
|
};
|
|
174
182
|
// Annotate the CommonJS export names for ESM import in node:
|
|
175
183
|
0 && (module.exports = {
|
|
176
184
|
build,
|
|
177
185
|
clean,
|
|
186
|
+
init,
|
|
178
187
|
inspect,
|
|
179
|
-
start
|
|
188
|
+
start,
|
|
189
|
+
validate
|
|
180
190
|
});
|
package/dist/index.mjs
CHANGED
|
@@ -59,7 +59,7 @@ function toHighlightedString(input) {
|
|
|
59
59
|
const inputAsString = JSON.stringify(
|
|
60
60
|
input,
|
|
61
61
|
function(_key, value) {
|
|
62
|
-
return typeof value === "function" ? value.
|
|
62
|
+
return typeof value === "function" ? value.name : value;
|
|
63
63
|
},
|
|
64
64
|
2
|
|
65
65
|
);
|
|
@@ -109,7 +109,11 @@ async function performBuild(buildOptions) {
|
|
|
109
109
|
}
|
|
110
110
|
|
|
111
111
|
// src/index.ts
|
|
112
|
-
|
|
112
|
+
import { updatePackageJsonFromTemplate } from "@procore/hammer-utils";
|
|
113
|
+
var { init, build, clean, inspect, start, validate } = {
|
|
114
|
+
init: async function init2(rootDir, config, options) {
|
|
115
|
+
await updatePackageJsonFromTemplate(rootDir, options.force);
|
|
116
|
+
},
|
|
113
117
|
build: async function build2(rootDir, config, options) {
|
|
114
118
|
const pluginOptions = { ...options, config };
|
|
115
119
|
const buildOptions = await createBuildOptions(base_configs_default, pluginOptions);
|
|
@@ -132,11 +136,15 @@ ${highlightedConfig}
|
|
|
132
136
|
const pluginOptions = { ...options, config, watch: true };
|
|
133
137
|
const buildOptions = await createBuildOptions(base_configs_default, pluginOptions);
|
|
134
138
|
await performBuild(buildOptions);
|
|
139
|
+
},
|
|
140
|
+
validate: async function validate2() {
|
|
135
141
|
}
|
|
136
142
|
};
|
|
137
143
|
export {
|
|
138
144
|
build,
|
|
139
145
|
clean,
|
|
146
|
+
init,
|
|
140
147
|
inspect,
|
|
141
|
-
start
|
|
148
|
+
start,
|
|
149
|
+
validate
|
|
142
150
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@procore/hammer-lib-tsup",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "Hammer library builder, tsup-style",
|
|
5
5
|
"author": "Procore Technologies, Inc",
|
|
6
6
|
"homepage": "https://github.com/procore/hammer/packages/lib-tsup",
|
|
@@ -27,12 +27,12 @@
|
|
|
27
27
|
"dist"
|
|
28
28
|
],
|
|
29
29
|
"engines": {
|
|
30
|
-
"node": "^18.
|
|
30
|
+
"node": "^18.18.0 || ^20.9.0 || ^22.0.0"
|
|
31
31
|
},
|
|
32
32
|
"scripts": {
|
|
33
33
|
"build": "tsup",
|
|
34
|
-
"clean": "
|
|
35
|
-
"exec": "exec",
|
|
34
|
+
"clean": "del dist coverage .eslintcache .turbo",
|
|
35
|
+
"exec": "yarn exec",
|
|
36
36
|
"format": "prettier --ignore-unknown --write --cache .",
|
|
37
37
|
"format:check": "prettier --ignore-unknown --check --cache .",
|
|
38
38
|
"lint:code": "eslint . --cache",
|
|
@@ -51,27 +51,29 @@
|
|
|
51
51
|
}
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"@procore/hammer-types": "^0.
|
|
54
|
+
"@procore/hammer-types": "^0.5.0",
|
|
55
|
+
"@procore/hammer-utils": "^0.1.0",
|
|
55
56
|
"cli-highlight": "^2.1.11",
|
|
56
|
-
"esbuild
|
|
57
|
+
"esbuild": "^0.23.1",
|
|
58
|
+
"esbuild-sass-plugin": "^3.3.1",
|
|
57
59
|
"pathe": "^1.1.2",
|
|
58
60
|
"picocolors": "^1.0.1",
|
|
59
|
-
"
|
|
60
|
-
"tsup": "^8.0
|
|
61
|
+
"sass-embedded": "^1.77.5",
|
|
62
|
+
"tsup": "^8.3.0"
|
|
61
63
|
},
|
|
62
64
|
"devDependencies": {
|
|
63
|
-
"@procore/eslint-config": "^15.2.
|
|
64
|
-
"@procore/
|
|
65
|
-
"@
|
|
66
|
-
"@
|
|
65
|
+
"@procore/eslint-config": "^15.2.1",
|
|
66
|
+
"@procore/hammer-test-utils": "^0.0.1",
|
|
67
|
+
"@procore/prettier-config": "^1.1.1",
|
|
68
|
+
"@procore/typescript-config": "^2.0.0",
|
|
69
|
+
"@types/node": "^20.16.10",
|
|
70
|
+
"@vitest/coverage-v8": "^2.1.1",
|
|
71
|
+
"del-cli": "^5.1.0",
|
|
67
72
|
"eslint": "^8.57.0",
|
|
68
|
-
"
|
|
69
|
-
"
|
|
70
|
-
"prettier": "^3.2.5",
|
|
71
|
-
"rimraf": "^5.0.7",
|
|
73
|
+
"postcss": "^8.4.39",
|
|
74
|
+
"prettier": "^3.3.3",
|
|
72
75
|
"strip-ansi": "^7.1.0",
|
|
73
|
-
"typescript": "^5.4
|
|
74
|
-
"vitest": "^1.
|
|
75
|
-
"vitest-mock-process": "^1.0.4"
|
|
76
|
+
"typescript": "^5.5.4",
|
|
77
|
+
"vitest": "^2.1.1"
|
|
76
78
|
}
|
|
77
79
|
}
|