@anolilab/semantic-release-clean-package-json 4.0.0-alpha.1 → 4.0.0-alpha.3

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 CHANGED
@@ -1,3 +1,25 @@
1
+ ## @anolilab/semantic-release-clean-package-json [4.0.0-alpha.3](https://github.com/anolilab/semantic-release/compare/@anolilab/semantic-release-clean-package-json@4.0.0-alpha.2...@anolilab/semantic-release-clean-package-json@4.0.0-alpha.3) (2025-11-20)
2
+
3
+ ### Miscellaneous Chores
4
+
5
+ * **release:** update changelogs for multi-semantic-release, rc, clean-package-json, and preset packages ([a0073c4](https://github.com/anolilab/semantic-release/commit/a0073c4ef4c582dc3514afc42b4ffbd07bf07761))
6
+
7
+
8
+ ### Dependencies
9
+
10
+ * **@anolilab/semantic-release-pnpm:** upgraded to 3.0.0-alpha.3
11
+
12
+ ## @anolilab/semantic-release-clean-package-json [4.0.0-alpha.2](https://github.com/anolilab/semantic-release/compare/@anolilab/semantic-release-clean-package-json@4.0.0-alpha.1...@anolilab/semantic-release-clean-package-json@4.0.0-alpha.2) (2025-10-21)
13
+
14
+ ### Bug Fixes
15
+
16
+ * update package manager and dependencies across multiple configurations ([07a4e0b](https://github.com/anolilab/semantic-release/commit/07a4e0be0c8ba0b8fc79f5d922bb62f60db38350))
17
+
18
+
19
+ ### Dependencies
20
+
21
+ * **@anolilab/semantic-release-pnpm:** upgraded to 3.0.0-alpha.2
22
+
1
23
  ## @anolilab/semantic-release-clean-package-json [4.0.0-alpha.1](https://github.com/anolilab/semantic-release/compare/@anolilab/semantic-release-clean-package-json@3.0.4...@anolilab/semantic-release-clean-package-json@4.0.0-alpha.1) (2025-10-14)
2
24
 
3
25
  ### ⚠ BREAKING CHANGES
@@ -15,6 +37,17 @@
15
37
 
16
38
  * **@anolilab/semantic-release-pnpm:** upgraded to 3.0.0-alpha.1
17
39
 
40
+ ## @anolilab/semantic-release-clean-package-json [3.0.5](https://github.com/anolilab/semantic-release/compare/@anolilab/semantic-release-clean-package-json@3.0.4...@anolilab/semantic-release-clean-package-json@3.0.5) (2025-11-01)
41
+
42
+ ### Bug Fixes
43
+
44
+ * update package dependencies and configurations ([d94ebd8](https://github.com/anolilab/semantic-release/commit/d94ebd8869c34106aa0c11beb0f7410bbc86367f))
45
+
46
+
47
+ ### Dependencies
48
+
49
+ * **@anolilab/semantic-release-pnpm:** upgraded to 2.0.5
50
+
18
51
  ## @anolilab/semantic-release-clean-package-json [3.0.4](https://github.com/anolilab/semantic-release/compare/@anolilab/semantic-release-clean-package-json@3.0.3...@anolilab/semantic-release-clean-package-json@3.0.4) (2025-09-22)
19
52
 
20
53
  ### Bug Fixes
@@ -136,31 +169,23 @@
136
169
 
137
170
  * **@anolilab/semantic-release-pnpm:** upgraded to 1.1.9
138
171
 
139
- ## @anolilab/semantic-release-clean-package-json 1.0.0 (2025-01-16)
140
-
141
- ### Features
142
-
143
- * new clean-package-json package for semantic-release ([#106](https://github.com/anolilab/semantic-release/issues/106)) ([94218d7](https://github.com/anolilab/semantic-release/commit/94218d72b21e698f46b96749d9216209782d381a))
172
+ ## @anolilab/semantic-release-clean-package-json [1.0.0-alpha.2](https://github.com/anolilab/semantic-release/compare/@anolilab/semantic-release-clean-package-json@1.0.0-alpha.1...@anolilab/semantic-release-clean-package-json@1.0.0-alpha.2) (2025-01-16)
144
173
 
145
174
  ### Bug Fixes
146
175
 
147
176
  * changed plugin order to not publish cleaned package.json to GitHub ([6673e69](https://github.com/anolilab/semantic-release/commit/6673e69723fd340380250fa2d986e4c37091351f))
148
- * remove usage of aggregate-error library ([e0c6e95](https://github.com/anolilab/semantic-release/commit/e0c6e95b07416d6694fa192ddca96e17a4c1c4b8))
149
- * **semantic-release-clean-package-json:** fixed circular dependency ([93b51f9](https://github.com/anolilab/semantic-release/commit/93b51f9c03503e10f0c0a23dcd55273622b40aa0))
150
- * **semantic-release-clean-package-json:** removed cjs exports, semantic-release don't support both types at the same time ([48c93c0](https://github.com/anolilab/semantic-release/commit/48c93c09cd5d6429b7658bc9a4fc573ea23462e2))
151
-
152
177
 
153
- ### Dependencies
178
+ ## @anolilab/semantic-release-clean-package-json 1.0.0-alpha.1 (2025-01-15)
154
179
 
155
- * **@anolilab/semantic-release-pnpm:** upgraded to 1.1.8
180
+ ### Features
156
181
 
157
- ## @anolilab/semantic-release-clean-package-json [1.0.0-alpha.2](https://github.com/anolilab/semantic-release/compare/@anolilab/semantic-release-clean-package-json@1.0.0-alpha.1...@anolilab/semantic-release-clean-package-json@1.0.0-alpha.2) (2025-01-16)
182
+ * new clean-package-json package for semantic-release ([#106](https://github.com/anolilab/semantic-release/issues/106)) ([94218d7](https://github.com/anolilab/semantic-release/commit/94218d72b21e698f46b96749d9216209782d381a))
158
183
 
159
184
  ### Bug Fixes
160
185
 
161
- * changed plugin order to not publish cleaned package.json to GitHub ([6673e69](https://github.com/anolilab/semantic-release/commit/6673e69723fd340380250fa2d986e4c37091351f))
186
+ * **semantic-release-clean-package-json:** fixed circular dependency ([93b51f9](https://github.com/anolilab/semantic-release/commit/93b51f9c03503e10f0c0a23dcd55273622b40aa0))
162
187
 
163
- ## @anolilab/semantic-release-clean-package-json 1.0.0-alpha.1 (2025-01-15)
188
+ ## @anolilab/semantic-release-clean-package-json 1.0.0 (2025-01-16)
164
189
 
165
190
  ### Features
166
191
 
@@ -168,4 +193,12 @@
168
193
 
169
194
  ### Bug Fixes
170
195
 
196
+ * changed plugin order to not publish cleaned package.json to GitHub ([6673e69](https://github.com/anolilab/semantic-release/commit/6673e69723fd340380250fa2d986e4c37091351f))
197
+ * remove usage of aggregate-error library ([e0c6e95](https://github.com/anolilab/semantic-release/commit/e0c6e95b07416d6694fa192ddca96e17a4c1c4b8))
171
198
  * **semantic-release-clean-package-json:** fixed circular dependency ([93b51f9](https://github.com/anolilab/semantic-release/commit/93b51f9c03503e10f0c0a23dcd55273622b40aa0))
199
+ * **semantic-release-clean-package-json:** removed cjs exports, semantic-release don't support both types at the same time ([48c93c0](https://github.com/anolilab/semantic-release/commit/48c93c09cd5d6429b7658bc9a4fc573ea23462e2))
200
+
201
+
202
+ ### Dependencies
203
+
204
+ * **@anolilab/semantic-release-pnpm:** upgraded to 1.1.8
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- var w=Object.defineProperty;var r=(s,e)=>w(s,"name",{value:e,configurable:!0});import{createRequire as b}from"node:module";import{findUp as E,readJson as f,writeJson as p,isAccessible as N}from"@visulima/fs";import{resolve as g,join as c}from"@visulima/path";import{NotFoundError as P}from"@visulima/fs/error";import O from"@semantic-release/error";const h=b(import.meta.url),y=r(s=>{if(process.versions?.node){const[e,o]=process.versions.node.split(".").map(Number);if(e>22||e===22&&o>=3||e===20&&o>=16)return process.getBuiltinModule(s)}return h(s)},"__cjs_getBuiltinModule"),J=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,{rm:v}=y("node:fs/promises"),_=["name","version","private","publishConfig","scripts.preinstall","scripts.install","scripts.postinstall","scripts.dependencies","files","bin","browser","main","man","jsdelivr","unpkg","dependencies","peerDependencies","peerDependenciesMeta","bundledDependencies","optionalDependencies","engines","os","cpu","description","keywords","author","contributors","license","homepage","repository","bugs","funding","type","exports","imports","sponsor","publisher","displayName","categories","galleryBanner","preview","contributes","activationEvents","badges","markdown","qna","extensionPack","extensionDependencies","extensionKind","icon","fesm2020","fesm2015","esm2020","es2020","types","typings","typesVersions","module","sideEffects"];var R=Object.defineProperty,l=r((s,e)=>R(s,"name",{value:e,configurable:!0}),"e");const K={ENOPKG:l(()=>({details:"A [package.json file](https://docs.npmjs.com/files/package.json) at the root of your project is required to release on npm.\nPlease follow the [npm guideline](https://docs.npmjs.com/getting-started/creating-node-modules) to create a valid `package.json` file.",message:"Missing `package.json` file."}),"ENOPKG"),ENOPKGNAME:l(()=>({details:"The `package.json`'s [name](https://docs.npmjs.com/files/package.json#name) property is required in order to publish a package to the npm registry.\nPlease make sure to add a valid `name` for your package in your `package.json`.",message:"Missing `name` property in `package.json`."}),"ENOPKGNAME")};var M=Object.defineProperty,A=r((s,e)=>M(s,"name",{value:e,configurable:!0}),"o");const u=A((s,e={})=>{const{details:o,message:t}=K[s](e);return new O(t,s,o)},"getError");var $=Object.defineProperty,m=r((s,e)=>$(s,"name",{value:e,configurable:!0}),"n");const q=m(async s=>{const e={type:"file"};s&&(e.cwd=s);const o=await E("package.json",e);if(!o)throw new P("No such file or directory, for package.json found.");return{packageJson:await f(o),path:o}},"findPackageJson"),k=m(async({pkgRoot:s},{cwd:e})=>{try{const{packageJson:o}=await q(s?g(e,s):e);if(!o.name){const t=u("ENOPKGNAME");throw new AggregateError([t],t.message)}return o}catch(o){if(o.code==="ENOENT"){const t=u("ENOPKG");throw new AggregateError([t],t.message)}throw o}},"getPackage");var G=Object.defineProperty,j=r((s,e)=>G(s,"name",{value:e,configurable:!0}),"c");const F=j(async(s,e)=>{const o=await k(s,e),t=s.pkgRoot?g(e.cwd,s.pkgRoot):e.cwd;await p(c(t,"package.json.back"),o,{detectIndent:!0}),e.logger.log("Created a backup of the package.json file.");const a=new Set([..._,...s.keep??[]]);e.logger.log(`Keeping the following properties: ${[...a].join(", ")}`);const n={...o};for(const i in n)if(!a.has(i)){if(i==="scripts"){for(const d in n.scripts)a.has(`${i}.${d}`)||delete n.scripts[d];if(n.scripts&&Object.keys(n.scripts).length>0)continue}e.logger.log(`Removing property "${i}"`),delete n[i]}await p(c(t,"package.json"),n,{detectIndent:!0})},"publish"),S=j(async(s,e)=>{const o=s.pkgRoot?g(e.cwd,s.pkgRoot):e.cwd,t=c(o,"package.json.back");if(await N(t)){const a=await k(s,e),n=await f(t);n.version=a.version,await p(c(o,"package.json"),n,{detectIndent:!0,overwrite:!0}),await v(t),e.logger.log("Restored modified package.json from backup.")}else e.logger.error("No backup package.json found.")},"success");export{F as publish,S as success};
1
+ var b=Object.defineProperty;var r=(s,e)=>b(s,"name",{value:e,configurable:!0});import{createRequire as y}from"node:module";import{findUp as N,readJson as m,writeJson as g,isAccessible as P}from"@visulima/fs";import{resolve as d,join as p}from"@visulima/path";import{NotFoundError as O}from"@visulima/fs/error";import _ from"@semantic-release/error";const h=y(import.meta.url),c=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,v=r(s=>{if(typeof c<"u"&&c.versions&&c.versions.node){const[e,o]=c.versions.node.split(".").map(Number);if(e>22||e===22&&o>=3||e===20&&o>=16)return c.getBuiltinModule(s)}return h(s)},"__cjs_getBuiltinModule"),{rm:E}=v("node:fs/promises"),R=["name","version","private","publishConfig","scripts.preinstall","scripts.install","scripts.postinstall","scripts.dependencies","files","bin","browser","main","man","jsdelivr","unpkg","dependencies","peerDependencies","peerDependenciesMeta","bundledDependencies","optionalDependencies","engines","os","cpu","description","keywords","author","contributors","license","homepage","repository","bugs","funding","type","exports","imports","sponsor","publisher","displayName","categories","galleryBanner","preview","contributes","activationEvents","badges","markdown","qna","extensionPack","extensionDependencies","extensionKind","icon","fesm2020","fesm2015","esm2020","es2020","types","typings","typesVersions","module","sideEffects"];var K=Object.defineProperty,u=r((s,e)=>K(s,"name",{value:e,configurable:!0}),"e");const M={ENOPKG:u(()=>({details:"A [package.json file](https://docs.npmjs.com/files/package.json) at the root of your project is required to release on npm.\nPlease follow the [npm guideline](https://docs.npmjs.com/getting-started/creating-node-modules) to create a valid `package.json` file.",message:"Missing `package.json` file."}),"ENOPKG"),ENOPKGNAME:u(()=>({details:"The `package.json`'s [name](https://docs.npmjs.com/files/package.json#name) property is required in order to publish a package to the npm registry.\nPlease make sure to add a valid `name` for your package in your `package.json`.",message:"Missing `name` property in `package.json`."}),"ENOPKGNAME")};var A=Object.defineProperty,$=r((s,e)=>A(s,"name",{value:e,configurable:!0}),"o");const f=$((s,e={})=>{const{details:o,message:t}=M[s](e);return new _(t,s,o)},"getError");var q=Object.defineProperty,k=r((s,e)=>q(s,"name",{value:e,configurable:!0}),"n");const G=k(async s=>{const e={type:"file"};s&&(e.cwd=s);const o=await N("package.json",e);if(!o)throw new O("No such file or directory, for package.json found.");return{packageJson:await m(o),path:o}},"findPackageJson"),j=k(async({pkgRoot:s},{cwd:e})=>{try{const{packageJson:o}=await G(s?d(e,s):e);if(!o.name){const t=f("ENOPKGNAME");throw new AggregateError([t],t.message)}return o}catch(o){if(o.code==="ENOENT"){const t=f("ENOPKG");throw new AggregateError([t],t.message)}throw o}},"getPackage");var x=Object.defineProperty,w=r((s,e)=>x(s,"name",{value:e,configurable:!0}),"c");const F=w(async(s,e)=>{const o=await j(s,e),t=s.pkgRoot?d(e.cwd,s.pkgRoot):e.cwd;await g(p(t,"package.json.back"),o,{detectIndent:!0}),e.logger.log("Created a backup of the package.json file.");const a=new Set([...R,...s.keep??[]]);e.logger.log(`Keeping the following properties: ${[...a].join(", ")}`);const n={...o};for(const i in n)if(!a.has(i)){if(i==="scripts"){for(const l in n.scripts)a.has(`${i}.${l}`)||delete n.scripts[l];if(n.scripts&&Object.keys(n.scripts).length>0)continue}e.logger.log(`Removing property "${i}"`),delete n[i]}await g(p(t,"package.json"),n,{detectIndent:!0})},"publish"),S=w(async(s,e)=>{const o=s.pkgRoot?d(e.cwd,s.pkgRoot):e.cwd,t=p(o,"package.json.back");if(await P(t)){const a=await j(s,e),n=await m(t);n.version=a.version,await g(p(o,"package.json"),n,{detectIndent:!0,overwrite:!0}),await E(t),e.logger.log("Restored modified package.json from backup.")}else e.logger.error("No backup package.json found.")},"success");export{F as publish,S as success};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anolilab/semantic-release-clean-package-json",
3
- "version": "4.0.0-alpha.1",
3
+ "version": "4.0.0-alpha.3",
4
4
  "description": "Clean package.json before publish by removing unnecessary properties",
5
5
  "keywords": [
6
6
  "anolilab",
@@ -45,9 +45,9 @@
45
45
  ],
46
46
  "dependencies": {
47
47
  "@semantic-release/error": "^4.0.0",
48
- "@visulima/fs": "^3.1.9",
49
- "@visulima/path": "^1.4.0",
50
- "type-fest": "^5.1.0"
48
+ "@visulima/fs": "^4.0.4",
49
+ "@visulima/path": "^2.0.3",
50
+ "type-fest": "^5.2.0"
51
51
  },
52
52
  "engines": {
53
53
  "node": "^22.14.0 || >=24.10.0"