lerna-clean-changelogs 5.0.9 → 5.0.10

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
@@ -3,7 +3,7 @@
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
- ## [5.0.8](https://github.com/codsen/codsen/compare/lerna-clean-changelogs@5.0.7...lerna-clean-changelogs@5.0.8) (2023-04-16)
6
+ ## 5.0.8 (2023-04-16)
7
7
 
8
8
  ### Bug Fixes
9
9
 
@@ -1,13 +1,13 @@
1
1
  /**
2
2
  * @name lerna-clean-changelogs
3
3
  * @fileoverview Removes frivolous entries from commitizen generated changelogs
4
- * @version 5.0.9
4
+ * @version 5.0.10
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/lerna-clean-changelogs/}
8
8
  */
9
9
 
10
- import{isStr as n,detectEol as f}from"codsen-utils";var m="5.0.9";var $=m,y={extras:!1};function x(s,u){if(s===void 0)throw new Error("lerna-clean-changelogs: [THROW_ID_01] The first input argument is missing!");if(!n(s))throw new Error(`lerna-clean-changelogs: [THROW_ID_02] The first input argument must be a string! It was given as ${Array.isArray(s)?"array":typeof s}, equal to:
10
+ import{isStr as n,detectEol as f}from"codsen-utils";var m="5.0.10";var $=m,y={extras:!1};function x(s,u){if(s===void 0)throw new Error("lerna-clean-changelogs: [THROW_ID_01] The first input argument is missing!");if(!n(s))throw new Error(`lerna-clean-changelogs: [THROW_ID_02] The first input argument must be a string! It was given as ${Array.isArray(s)?"array":typeof s}, equal to:
11
11
  ${JSON.stringify(s,null,4)}`);let o={...y,...u},a=f(s)||`
12
12
  `,p,l=!1;if(typeof s=="string"&&s?.trim()){let c=n(s)&&!!s.length&&(s[~-s.length]===`
13
13
  `||s[~-s.length]==="\r");s=s?.trim().replace(/(https:\/\/git\.sr\.ht\/~[^/]+\/[^/]+\/)commits\//g,"$1commit/");let t=s.split(/\r?\n/);o.extras&&t.forEach((e,r)=>{e?.startsWith("#")&&(t[r]=e.replace(/(#+) \[?(\d+\.\d+\.\d+)\s?\]\([^)]*\)/g,"$1 $2")),r&&t[r]?.startsWith("# ")&&(t[r]=`#${t[r]}`)});let i=[];for(let e=t.length;e--;){if(t[e]?.startsWith("**Note:** Version bump only")||o.extras&&t[e].toLowerCase().includes("wip")){for(;e&&n(t[~-e])&&!t[~-e]?.trim();)e-=1;for(e&&n(t[~-e])&&t[~-e]?.trim()?.startsWith("#")&&(e-=1);e&&n(t[~-e])&&!t[~-e]?.trim();)e-=1}else t[e]?.trim()?t[e][0]==="*"&&t[e][1]===" "?i.unshift(`- ${t[e].slice(2)}`):i.unshift(t[e]):l||(i.unshift(t[e]?.trim()),l=!0);t[e]?.trim()&&(l=!1)}p=`${i.join(a)}${c?a:""}`}return{version:$,res:p||s}}export{x as cleanChangelogs,y as defaults,$ as version};
@@ -1,24 +1,24 @@
1
1
  /**
2
2
  * @name lerna-clean-changelogs
3
3
  * @fileoverview Removes frivolous entries from commitizen generated changelogs
4
- * @version 5.0.9
4
+ * @version 5.0.10
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/lerna-clean-changelogs/}
8
8
  */
9
9
 
10
- "use strict";var lernaCleanChangelogs=(()=>{var c=Object.defineProperty;var k=Object.getOwnPropertyDescriptor;var j=Object.getOwnPropertyNames,x=Object.getOwnPropertySymbols;var S=Object.prototype.hasOwnProperty,B=Object.prototype.propertyIsEnumerable;var v=(e,t,n)=>t in e?c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,m=(e,t)=>{for(var n in t||(t={}))S.call(t,n)&&v(e,n,t[n]);if(x)for(var n of x(t))B.call(t,n)&&v(e,n,t[n]);return e};var T=(e,t)=>{for(var n in t)c(e,n,{get:t[n],enumerable:!0})},N=(e,t,n,a)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of j(t))!S.call(e,i)&&i!==n&&c(e,i,{get:()=>t[i],enumerable:!(a=k(t,i))||a.enumerable});return e};var R=e=>N(c({},"__esModule",{value:!0}),e);var V={};T(V,{cleanChangelogs:()=>F,defaults:()=>L,version:()=>D});function u(e){return typeof e=="string"}function w(e){if(!(typeof e!="string"||!e)){if(e.includes(`\r
10
+ "use strict";var lernaCleanChangelogs=(()=>{var V=Object.create;var h=Object.defineProperty;var R=Object.getOwnPropertyDescriptor;var W=Object.getOwnPropertyNames,S=Object.getOwnPropertySymbols,P=Object.getPrototypeOf,E=Object.prototype.hasOwnProperty,F=Object.prototype.propertyIsEnumerable;var D=(e,n,a)=>n in e?h(e,n,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[n]=a,$=(e,n)=>{for(var a in n||(n={}))E.call(n,a)&&D(e,a,n[a]);if(S)for(var a of S(n))F.call(n,a)&&D(e,a,n[a]);return e};var I=(e,n)=>()=>(n||e((n={exports:{}}).exports,n),n.exports),J=(e,n)=>{for(var a in n)h(e,a,{get:n[a],enumerable:!0})},x=(e,n,a,u)=>{if(n&&typeof n=="object"||typeof n=="function")for(let s of W(n))!E.call(e,s)&&s!==a&&h(e,s,{get:()=>n[s],enumerable:!(u=R(n,s))||u.enumerable});return e};var Q=(e,n,a)=>(a=e!=null?V(P(e)):{},x(n||!e||!e.__esModule?h(a,"default",{value:e,enumerable:!0}):a,e)),_=e=>x(h({},"__esModule",{value:!0}),e);var j=I((G,O)=>{"use strict";O.exports=U;function d(e){return e instanceof Buffer?Buffer.from(e):new e.constructor(e.buffer.slice(),e.byteOffset,e.length)}function U(e){if(e=e||{},e.circles)return H(e);return e.proto?u:a;function n(s,l){for(var r=Object.keys(s),t=new Array(r.length),o=0;o<r.length;o++){var i=r[o],p=s[i];typeof p!="object"||p===null?t[i]=p:p instanceof Date?t[i]=new Date(p):ArrayBuffer.isView(p)?t[i]=d(p):t[i]=l(p)}return t}function a(s){if(typeof s!="object"||s===null)return s;if(s instanceof Date)return new Date(s);if(Array.isArray(s))return n(s,a);if(s instanceof Map)return new Map(n(Array.from(s),a));if(s instanceof Set)return new Set(n(Array.from(s),a));var l={};for(var r in s)if(Object.hasOwnProperty.call(s,r)!==!1){var t=s[r];typeof t!="object"||t===null?l[r]=t:t instanceof Date?l[r]=new Date(t):t instanceof Map?l[r]=new Map(n(Array.from(t),a)):t instanceof Set?l[r]=new Set(n(Array.from(t),a)):ArrayBuffer.isView(t)?l[r]=d(t):l[r]=a(t)}return l}function u(s){if(typeof s!="object"||s===null)return s;if(s instanceof Date)return new Date(s);if(Array.isArray(s))return n(s,u);if(s instanceof Map)return new Map(n(Array.from(s),u));if(s instanceof Set)return new Set(n(Array.from(s),u));var l={};for(var r in s){var t=s[r];typeof t!="object"||t===null?l[r]=t:t instanceof Date?l[r]=new Date(t):t instanceof Map?l[r]=new Map(n(Array.from(t),u)):t instanceof Set?l[r]=new Set(n(Array.from(t),u)):ArrayBuffer.isView(t)?l[r]=d(t):l[r]=u(t)}return l}}function H(e){var n=[],a=[];return e.proto?l:s;function u(r,t){for(var o=Object.keys(r),i=new Array(o.length),p=0;p<o.length;p++){var y=o[p],m=r[y];if(typeof m!="object"||m===null)i[y]=m;else if(m instanceof Date)i[y]=new Date(m);else if(ArrayBuffer.isView(m))i[y]=d(m);else{var A=n.indexOf(m);A!==-1?i[y]=a[A]:i[y]=t(m)}}return i}function s(r){if(typeof r!="object"||r===null)return r;if(r instanceof Date)return new Date(r);if(Array.isArray(r))return u(r,s);if(r instanceof Map)return new Map(u(Array.from(r),s));if(r instanceof Set)return new Set(u(Array.from(r),s));var t={};n.push(r),a.push(t);for(var o in r)if(Object.hasOwnProperty.call(r,o)!==!1){var i=r[o];if(typeof i!="object"||i===null)t[o]=i;else if(i instanceof Date)t[o]=new Date(i);else if(i instanceof Map)t[o]=new Map(u(Array.from(i),s));else if(i instanceof Set)t[o]=new Set(u(Array.from(i),s));else if(ArrayBuffer.isView(i))t[o]=d(i);else{var p=n.indexOf(i);p!==-1?t[o]=a[p]:t[o]=s(i)}}return n.pop(),a.pop(),t}function l(r){if(typeof r!="object"||r===null)return r;if(r instanceof Date)return new Date(r);if(Array.isArray(r))return u(r,l);if(r instanceof Map)return new Map(u(Array.from(r),l));if(r instanceof Set)return new Set(u(Array.from(r),l));var t={};n.push(r),a.push(t);for(var o in r){var i=r[o];if(typeof i!="object"||i===null)t[o]=i;else if(i instanceof Date)t[o]=new Date(i);else if(i instanceof Map)t[o]=new Map(u(Array.from(i),l));else if(i instanceof Set)t[o]=new Set(u(Array.from(i),l));else if(ArrayBuffer.isView(i))t[o]=d(i);else{var p=n.indexOf(i);p!==-1?t[o]=a[p]:t[o]=l(i)}}return n.pop(),a.pop(),t}}});var K={};J(K,{cleanChangelogs:()=>z,defaults:()=>T,version:()=>M});var C=Q(j(),1);var X=(0,C.default)();function b(e){return typeof e=="string"}function B(e){if(!(typeof e!="string"||!e)){if(e.includes(`\r
11
11
  `))return`\r
12
12
  `;if(e.includes(`
13
13
  `))return`
14
- `;if(e.includes("\r"))return"\r"}}var C="5.0.9";var D=C,L={extras:!1};function F(e,t){var f,d,b,$,h,y,g,A;if(e===void 0)throw new Error("lerna-clean-changelogs: [THROW_ID_01] The first input argument is missing!");if(!u(e))throw new Error(`lerna-clean-changelogs: [THROW_ID_02] The first input argument must be a string! It was given as ${Array.isArray(e)?"array":typeof e}, equal to:
15
- ${JSON.stringify(e,null,4)}`);let n=m(m({},L),t),a=w(e)||`
16
- `,i,p=!1;if(typeof e=="string"&&(e!=null&&e.trim())){let O=u(e)&&!!e.length&&(e[~-e.length]===`
17
- `||e[~-e.length]==="\r");e=e==null?void 0:e.trim().replace(/(https:\/\/git\.sr\.ht\/~[^/]+\/[^/]+\/)commits\//g,"$1commit/");let s=e.split(/\r?\n/);n.extras&&s.forEach((r,o)=>{var E;r!=null&&r.startsWith("#")&&(s[o]=r.replace(/(#+) \[?(\d+\.\d+\.\d+)\s?\]\([^)]*\)/g,"$1 $2")),o&&((E=s[o])!=null&&E.startsWith("# "))&&(s[o]=`#${s[o]}`)});let l=[];for(let r=s.length;r--;){if((f=s[r])!=null&&f.startsWith("**Note:** Version bump only")||n.extras&&s[r].toLowerCase().includes("wip")){for(;r&&u(s[~-r])&&!((d=s[~-r])!=null&&d.trim());)r-=1;for(r&&u(s[~-r])&&(($=(b=s[~-r])==null?void 0:b.trim())!=null&&$.startsWith("#"))&&(r-=1);r&&u(s[~-r])&&!((h=s[~-r])!=null&&h.trim());)r-=1}else(y=s[r])!=null&&y.trim()?s[r][0]==="*"&&s[r][1]===" "?l.unshift(`- ${s[r].slice(2)}`):l.unshift(s[r]):p||(l.unshift((g=s[r])==null?void 0:g.trim()),p=!0);(A=s[r])!=null&&A.trim()&&(p=!1)}i=`${l.join(a)}${O?a:""}`}return{version:D,res:i||e}}return R(V);})();
14
+ `;if(e.includes("\r"))return"\r"}}var L="5.0.10";var M=L,T={extras:!1};function z(e,n){var r,t,o,i,p,y,m,A;if(e===void 0)throw new Error("lerna-clean-changelogs: [THROW_ID_01] The first input argument is missing!");if(!b(e))throw new Error(`lerna-clean-changelogs: [THROW_ID_02] The first input argument must be a string! It was given as ${Array.isArray(e)?"array":typeof e}, equal to:
15
+ ${JSON.stringify(e,null,4)}`);let a=$($({},T),n),u=B(e)||`
16
+ `,s,l=!1;if(typeof e=="string"&&(e!=null&&e.trim())){let N=b(e)&&!!e.length&&(e[~-e.length]===`
17
+ `||e[~-e.length]==="\r");e=e==null?void 0:e.trim().replace(/(https:\/\/git\.sr\.ht\/~[^/]+\/[^/]+\/)commits\//g,"$1commit/");let c=e.split(/\r?\n/);a.extras&&c.forEach((f,w)=>{var g;f!=null&&f.startsWith("#")&&(c[w]=f.replace(/(#+) \[?(\d+\.\d+\.\d+)\s?\]\([^)]*\)/g,"$1 $2")),w&&((g=c[w])!=null&&g.startsWith("# "))&&(c[w]=`#${c[w]}`)});let v=[];for(let f=c.length;f--;){if((r=c[f])!=null&&r.startsWith("**Note:** Version bump only")||a.extras&&c[f].toLowerCase().includes("wip")){for(;f&&b(c[~-f])&&!((t=c[~-f])!=null&&t.trim());)f-=1;for(f&&b(c[~-f])&&((i=(o=c[~-f])==null?void 0:o.trim())!=null&&i.startsWith("#"))&&(f-=1);f&&b(c[~-f])&&!((p=c[~-f])!=null&&p.trim());)f-=1}else(y=c[f])!=null&&y.trim()?c[f][0]==="*"&&c[f][1]===" "?v.unshift(`- ${c[f].slice(2)}`):v.unshift(c[f]):l||(v.unshift((m=c[f])==null?void 0:m.trim()),l=!0);(A=c[f])!=null&&A.trim()&&(l=!1)}s=`${v.join(u)}${N?u:""}`}return{version:M,res:s||e}}return _(K);})();
18
18
  /**
19
19
  * @name codsen-utils
20
20
  * @fileoverview Various utility functions
21
- * @version 1.5.0
21
+ * @version 1.6.0
22
22
  * @author Roy Revelt, Codsen Ltd
23
23
  * @license MIT
24
24
  * {@link https://codsen.com/os/codsen-utils/}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lerna-clean-changelogs",
3
- "version": "5.0.9",
3
+ "version": "5.0.10",
4
4
  "description": "Removes frivolous entries from commitizen generated changelogs",
5
5
  "keywords": [
6
6
  "changelog",
@@ -72,6 +72,6 @@
72
72
  }
73
73
  },
74
74
  "dependencies": {
75
- "codsen-utils": "^1.5.0"
75
+ "codsen-utils": "^1.6.0"
76
76
  }
77
77
  }