pob 26.8.0 → 26.9.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 +14 -0
- package/lib/generators/common/release/templates/workflow-release.yml.ejs +2 -1
- package/lib/generators/core/ci/templates/github-action-documentation-workflow.yml.ejs +2 -1
- package/lib/generators/core/ci/templates/github-action-push-workflow-split.yml.ejs +15 -9
- package/lib/generators/core/ci/templates/github-action-push-workflow.yml.ejs +2 -1
- package/package.json +6 -7
- package/lib/generators/common/format-lint/updateEslintConfig.js +0 -155
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,20 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [26.9.0](https://github.com/christophehurpeau/pob/compare/pob@26.8.0...pob@26.9.0) (2025-02-22)
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* use option check-latest: true in setup-node ci action ([63bdec9](https://github.com/christophehurpeau/pob/commit/63bdec956723a872f0bde486a9212c4cf60d2de0))
|
|
11
|
+
|
|
12
|
+
### Reverts
|
|
13
|
+
|
|
14
|
+
* Revert "feat: update node ci usage to 22.14" ([dab8648](https://github.com/christophehurpeau/pob/commit/dab86485e6eb0d833521660943b0db37aaa3d9f8))
|
|
15
|
+
|
|
16
|
+
Version bump for dependency: @pob/sort-pkg
|
|
17
|
+
Version bump for dependency: @pob/root
|
|
18
|
+
|
|
19
|
+
|
|
6
20
|
## [26.8.0](https://github.com/christophehurpeau/pob/compare/pob@26.7.0...pob@26.8.0) (2025-02-17)
|
|
7
21
|
|
|
8
22
|
### Features
|
|
@@ -12,7 +12,8 @@ jobs:
|
|
|
12
12
|
|
|
13
13
|
- uses: actions/setup-node@v4
|
|
14
14
|
with:
|
|
15
|
-
node-version: 22
|
|
15
|
+
node-version: 22
|
|
16
|
+
check-latest: true
|
|
16
17
|
|
|
17
18
|
- name: Enable Corepack
|
|
18
19
|
run: corepack enable
|
|
@@ -41,7 +42,8 @@ jobs:
|
|
|
41
42
|
|
|
42
43
|
- uses: actions/setup-node@v4
|
|
43
44
|
with:
|
|
44
|
-
node-version: 22
|
|
45
|
+
node-version: 22
|
|
46
|
+
check-latest: true
|
|
45
47
|
|
|
46
48
|
- name: Enable Corepack
|
|
47
49
|
run: corepack enable
|
|
@@ -72,7 +74,8 @@ jobs:
|
|
|
72
74
|
|
|
73
75
|
- uses: actions/setup-node@v4
|
|
74
76
|
with:
|
|
75
|
-
node-version: 22
|
|
77
|
+
node-version: 22
|
|
78
|
+
check-latest: true
|
|
76
79
|
|
|
77
80
|
- name: Enable Corepack
|
|
78
81
|
run: corepack enable
|
|
@@ -101,7 +104,7 @@ jobs:
|
|
|
101
104
|
|
|
102
105
|
strategy:
|
|
103
106
|
matrix:
|
|
104
|
-
node-version: [20, 22
|
|
107
|
+
node-version: [20, 22]
|
|
105
108
|
|
|
106
109
|
steps:
|
|
107
110
|
- uses: actions/checkout@v4
|
|
@@ -109,6 +112,7 @@ jobs:
|
|
|
109
112
|
- uses: actions/setup-node@v4
|
|
110
113
|
with:
|
|
111
114
|
node-version: ${{ matrix.node-version }}
|
|
115
|
+
check-latest: true
|
|
112
116
|
|
|
113
117
|
<% if (packageManager === 'yarn') { -%>
|
|
114
118
|
- name: Enable Corepack
|
|
@@ -131,17 +135,17 @@ jobs:
|
|
|
131
135
|
<% if (codecov) { -%>
|
|
132
136
|
- name: Test
|
|
133
137
|
run: <%= packageManager %> run test
|
|
134
|
-
if: matrix.node-version !=
|
|
138
|
+
if: matrix.node-version != 22
|
|
135
139
|
|
|
136
140
|
- name: Generate Test Coverage
|
|
137
141
|
run: <%= packageManager %> run test:coverage:json
|
|
138
|
-
if: matrix.node-version ==
|
|
142
|
+
if: matrix.node-version == 22
|
|
139
143
|
env:
|
|
140
144
|
CI: true
|
|
141
145
|
|
|
142
146
|
- name: Send results to codecov
|
|
143
147
|
uses: codecov/codecov-action@v5
|
|
144
|
-
if: matrix.node-version ==
|
|
148
|
+
if: matrix.node-version == 22 && github.actor != 'dependabot[bot]'
|
|
145
149
|
with:
|
|
146
150
|
fail_ci_if_error: true
|
|
147
151
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
@@ -158,7 +162,7 @@ jobs:
|
|
|
158
162
|
|
|
159
163
|
strategy:
|
|
160
164
|
matrix:
|
|
161
|
-
node-version: [22
|
|
165
|
+
node-version: [22]
|
|
162
166
|
|
|
163
167
|
steps:
|
|
164
168
|
- uses: actions/checkout@v4
|
|
@@ -166,6 +170,7 @@ jobs:
|
|
|
166
170
|
- uses: actions/setup-node@v4
|
|
167
171
|
with:
|
|
168
172
|
node-version: ${{ matrix.node-version }}
|
|
173
|
+
check-latest: true
|
|
169
174
|
|
|
170
175
|
- name: Enable Corepack
|
|
171
176
|
run: corepack enable
|
|
@@ -191,7 +196,8 @@ jobs:
|
|
|
191
196
|
|
|
192
197
|
- uses: actions/setup-node@v4
|
|
193
198
|
with:
|
|
194
|
-
node-version: 22
|
|
199
|
+
node-version: 22
|
|
200
|
+
check-latest: true
|
|
195
201
|
|
|
196
202
|
- uses: GoogleCloudPlatform/release-please-action@v3
|
|
197
203
|
if: ${{ github.ref == 'refs/heads/main' }}
|
|
@@ -8,7 +8,7 @@ jobs:
|
|
|
8
8
|
|
|
9
9
|
strategy:
|
|
10
10
|
matrix:
|
|
11
|
-
node-version: [<% if (!onlyLatestLTS) { -%>20.x, <% } -%>22.
|
|
11
|
+
node-version: [<% if (!onlyLatestLTS) { -%>20.x, <% } -%>22.x]
|
|
12
12
|
|
|
13
13
|
steps:
|
|
14
14
|
- uses: actions/checkout@v4
|
|
@@ -17,6 +17,7 @@ jobs:
|
|
|
17
17
|
uses: actions/setup-node@v4
|
|
18
18
|
with:
|
|
19
19
|
node-version: ${{ matrix.node-version }}
|
|
20
|
+
check-latest: true
|
|
20
21
|
registry-url: 'https://registry.npmjs.org'
|
|
21
22
|
|
|
22
23
|
<% if (packageManager === 'yarn') { -%>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pob",
|
|
3
|
-
"version": "26.
|
|
3
|
+
"version": "26.9.0",
|
|
4
4
|
"description": "Pile of bones, library generator with git/babel/typescript/typedoc/readme/jest",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"skeleton"
|
|
@@ -44,9 +44,8 @@
|
|
|
44
44
|
"@pob/eslint-config": "59.7.0",
|
|
45
45
|
"@pob/eslint-config-typescript": "59.7.0",
|
|
46
46
|
"@pob/eslint-config-typescript-react": "59.7.0",
|
|
47
|
-
"@pob/sort-eslint-config": "8.0.0",
|
|
48
47
|
"@pob/sort-object": "9.0.0",
|
|
49
|
-
"@pob/sort-pkg": "11.0.
|
|
48
|
+
"@pob/sort-pkg": "11.0.1",
|
|
50
49
|
"@prettier/sync": "0.5.2",
|
|
51
50
|
"@types/inquirer": "9.0.7",
|
|
52
51
|
"@yarnpkg/cli": "4.6.0",
|
|
@@ -65,8 +64,8 @@
|
|
|
65
64
|
"mem-fs-editor": "11.1.4",
|
|
66
65
|
"minimist": "1.2.8",
|
|
67
66
|
"parse-author": "2.0.0",
|
|
68
|
-
"pob-dependencies": "17.
|
|
69
|
-
"prettier": "3.5.
|
|
67
|
+
"pob-dependencies": "17.7.0",
|
|
68
|
+
"prettier": "3.5.2",
|
|
70
69
|
"semver": "7.7.1",
|
|
71
70
|
"typescript": "5.7.3",
|
|
72
71
|
"validate-npm-package-name": "^6.0.0",
|
|
@@ -75,7 +74,7 @@
|
|
|
75
74
|
"yeoman-generator": "7.4.0"
|
|
76
75
|
},
|
|
77
76
|
"devDependencies": {
|
|
78
|
-
"@pob/root": "16.
|
|
79
|
-
"@types/node": "22.13.
|
|
77
|
+
"@pob/root": "16.7.0",
|
|
78
|
+
"@types/node": "22.13.5"
|
|
80
79
|
}
|
|
81
80
|
}
|
|
@@ -1,155 +0,0 @@
|
|
|
1
|
-
import sortConfig from "@pob/sort-eslint-config";
|
|
2
|
-
|
|
3
|
-
function updateOverrides(config, testsOverride) {
|
|
4
|
-
const existingTestsOverrideIndex = !config.overrides
|
|
5
|
-
? -1
|
|
6
|
-
: config.overrides.findIndex(
|
|
7
|
-
testsOverride.env?.jest
|
|
8
|
-
? (override) => override.env && override.env.jest
|
|
9
|
-
: (override) =>
|
|
10
|
-
override?.env?.jest ||
|
|
11
|
-
override.extends?.includes(testsOverride.extends[0]),
|
|
12
|
-
);
|
|
13
|
-
if (!testsOverride) {
|
|
14
|
-
if (existingTestsOverrideIndex !== -1) {
|
|
15
|
-
config.overrides.splice(existingTestsOverrideIndex, 1);
|
|
16
|
-
if (config.overrides.length === 0) {
|
|
17
|
-
delete config.overrides;
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
} else {
|
|
21
|
-
if (testsOverride.rules && Object.keys(testsOverride.rules).length === 0) {
|
|
22
|
-
delete testsOverride.rules;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
if (existingTestsOverrideIndex !== -1) {
|
|
26
|
-
const existingTestsOverride =
|
|
27
|
-
config.overrides[existingTestsOverrideIndex];
|
|
28
|
-
Object.assign(existingTestsOverride, testsOverride);
|
|
29
|
-
|
|
30
|
-
if (
|
|
31
|
-
existingTestsOverride.rules &&
|
|
32
|
-
Object.keys(existingTestsOverride.rules).length === 0
|
|
33
|
-
) {
|
|
34
|
-
delete existingTestsOverride.rules;
|
|
35
|
-
}
|
|
36
|
-
} else {
|
|
37
|
-
if (!config.overrides) config.overrides = [];
|
|
38
|
-
config.overrides.push(testsOverride);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
return config;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
function updateParserAndPlugins(
|
|
45
|
-
config,
|
|
46
|
-
useTypescript,
|
|
47
|
-
globalEslint,
|
|
48
|
-
relativePath,
|
|
49
|
-
) {
|
|
50
|
-
if (useTypescript) {
|
|
51
|
-
// webstorm uses this to detect eslint .ts compat
|
|
52
|
-
config.parser = "@typescript-eslint/parser";
|
|
53
|
-
config.plugins = ["@typescript-eslint"];
|
|
54
|
-
|
|
55
|
-
if (!globalEslint) {
|
|
56
|
-
config.parserOptions = {
|
|
57
|
-
project: "./tsconfig.json",
|
|
58
|
-
createDefaultProgram: true, // fix for lint-staged
|
|
59
|
-
};
|
|
60
|
-
} else {
|
|
61
|
-
config.parserOptions = {
|
|
62
|
-
// EXPERIMENTAL_useProjectService: true,
|
|
63
|
-
project: `${relativePath}/tsconfig.json`,
|
|
64
|
-
};
|
|
65
|
-
}
|
|
66
|
-
} else {
|
|
67
|
-
if (
|
|
68
|
-
config.parser === "typescript-eslint-parser" ||
|
|
69
|
-
config.parser === "@typescript-eslint/parser"
|
|
70
|
-
) {
|
|
71
|
-
delete config.parser;
|
|
72
|
-
}
|
|
73
|
-
if (config.parserOptions && config.parserOptions.project) {
|
|
74
|
-
delete config.parserOptions;
|
|
75
|
-
}
|
|
76
|
-
if (
|
|
77
|
-
config.plugins &&
|
|
78
|
-
(config.plugins[0] === "typescript" ||
|
|
79
|
-
config.plugins[0] === "@typescript-eslint")
|
|
80
|
-
) {
|
|
81
|
-
config.plugins.splice(0, 1);
|
|
82
|
-
}
|
|
83
|
-
if (config.plugins && config.plugins.length === 0) {
|
|
84
|
-
delete config.plugins;
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
return config;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
function updateSettings(config, settings) {
|
|
92
|
-
Object.entries(settings).forEach(([key, value]) => {
|
|
93
|
-
if (value === false) {
|
|
94
|
-
if (config.settings) {
|
|
95
|
-
delete config.settings[key];
|
|
96
|
-
}
|
|
97
|
-
} else {
|
|
98
|
-
if (!config.settings) config.settings = {};
|
|
99
|
-
config.settings[key] = value;
|
|
100
|
-
}
|
|
101
|
-
});
|
|
102
|
-
|
|
103
|
-
if (config.settings && Object.keys(config.settings) === 0) {
|
|
104
|
-
delete config.settings;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
return config;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
function updateIgnorePatterns(config, ignorePatterns) {
|
|
111
|
-
if (!ignorePatterns) {
|
|
112
|
-
delete config.ignorePatterns;
|
|
113
|
-
} else {
|
|
114
|
-
config.ignorePatterns = ignorePatterns;
|
|
115
|
-
}
|
|
116
|
-
return config;
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
export default function updateEslintConfig(
|
|
120
|
-
config,
|
|
121
|
-
{
|
|
122
|
-
extendsConfig,
|
|
123
|
-
testsOverride,
|
|
124
|
-
useTypescript,
|
|
125
|
-
globalEslint,
|
|
126
|
-
settings,
|
|
127
|
-
ignorePatterns,
|
|
128
|
-
relativePath,
|
|
129
|
-
},
|
|
130
|
-
) {
|
|
131
|
-
config.root = true;
|
|
132
|
-
config.extends = [
|
|
133
|
-
...extendsConfig,
|
|
134
|
-
...(config?.extends && Array.isArray(config.extends)
|
|
135
|
-
? config.extends.filter(
|
|
136
|
-
(extendsValue) =>
|
|
137
|
-
extendsValue === "@pob/eslint-config-typescript/allow-unsafe",
|
|
138
|
-
)
|
|
139
|
-
: []),
|
|
140
|
-
];
|
|
141
|
-
|
|
142
|
-
config = updateParserAndPlugins(
|
|
143
|
-
config,
|
|
144
|
-
useTypescript,
|
|
145
|
-
globalEslint,
|
|
146
|
-
relativePath,
|
|
147
|
-
);
|
|
148
|
-
config = updateOverrides(config, testsOverride);
|
|
149
|
-
if (settings) {
|
|
150
|
-
config = updateSettings(config, settings);
|
|
151
|
-
}
|
|
152
|
-
config = updateIgnorePatterns(config, ignorePatterns);
|
|
153
|
-
|
|
154
|
-
return sortConfig(config);
|
|
155
|
-
}
|