@hyperfrontend/versioning 0.1.0 → 0.2.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/ARCHITECTURE.md +50 -1
- package/CHANGELOG.md +23 -23
- package/README.md +12 -9
- package/changelog/index.cjs.js +23 -2
- package/changelog/index.cjs.js.map +1 -1
- package/changelog/index.esm.js +23 -2
- package/changelog/index.esm.js.map +1 -1
- package/changelog/models/entry.d.ts +5 -0
- package/changelog/models/entry.d.ts.map +1 -1
- package/changelog/models/index.cjs.js +2 -0
- package/changelog/models/index.cjs.js.map +1 -1
- package/changelog/models/index.esm.js +2 -0
- package/changelog/models/index.esm.js.map +1 -1
- package/changelog/operations/index.cjs.js.map +1 -1
- package/changelog/operations/index.esm.js.map +1 -1
- package/changelog/parse/index.cjs.js +23 -2
- package/changelog/parse/index.cjs.js.map +1 -1
- package/changelog/parse/index.esm.js +23 -2
- package/changelog/parse/index.esm.js.map +1 -1
- package/changelog/parse/line.d.ts.map +1 -1
- package/commits/classify/classifier.d.ts +73 -0
- package/commits/classify/classifier.d.ts.map +1 -0
- package/commits/classify/index.cjs.js +705 -0
- package/commits/classify/index.cjs.js.map +1 -0
- package/commits/classify/index.d.ts +8 -0
- package/commits/classify/index.d.ts.map +1 -0
- package/commits/classify/index.esm.js +678 -0
- package/commits/classify/index.esm.js.map +1 -0
- package/commits/classify/infrastructure.d.ts +205 -0
- package/commits/classify/infrastructure.d.ts.map +1 -0
- package/commits/classify/models.d.ts +108 -0
- package/commits/classify/models.d.ts.map +1 -0
- package/commits/classify/project-scopes.d.ts +59 -0
- package/commits/classify/project-scopes.d.ts.map +1 -0
- package/commits/index.cjs.js +702 -0
- package/commits/index.cjs.js.map +1 -1
- package/commits/index.d.ts +1 -0
- package/commits/index.d.ts.map +1 -1
- package/commits/index.esm.js +677 -1
- package/commits/index.esm.js.map +1 -1
- package/flow/executor/execute.d.ts +6 -0
- package/flow/executor/execute.d.ts.map +1 -1
- package/flow/executor/index.cjs.js +1604 -42
- package/flow/executor/index.cjs.js.map +1 -1
- package/flow/executor/index.esm.js +1610 -48
- package/flow/executor/index.esm.js.map +1 -1
- package/flow/index.cjs.js +6651 -2893
- package/flow/index.cjs.js.map +1 -1
- package/flow/index.esm.js +6655 -2899
- package/flow/index.esm.js.map +1 -1
- package/flow/models/index.cjs.js +125 -0
- package/flow/models/index.cjs.js.map +1 -1
- package/flow/models/index.esm.js +125 -0
- package/flow/models/index.esm.js.map +1 -1
- package/flow/models/types.d.ts +148 -3
- package/flow/models/types.d.ts.map +1 -1
- package/flow/presets/conventional.d.ts +9 -8
- package/flow/presets/conventional.d.ts.map +1 -1
- package/flow/presets/independent.d.ts.map +1 -1
- package/flow/presets/index.cjs.js +3588 -298
- package/flow/presets/index.cjs.js.map +1 -1
- package/flow/presets/index.esm.js +3588 -298
- package/flow/presets/index.esm.js.map +1 -1
- package/flow/presets/synced.d.ts.map +1 -1
- package/flow/steps/analyze-commits.d.ts +9 -6
- package/flow/steps/analyze-commits.d.ts.map +1 -1
- package/flow/steps/calculate-bump.d.ts.map +1 -1
- package/flow/steps/fetch-registry.d.ts.map +1 -1
- package/flow/steps/generate-changelog.d.ts.map +1 -1
- package/flow/steps/index.cjs.js +3604 -318
- package/flow/steps/index.cjs.js.map +1 -1
- package/flow/steps/index.d.ts +1 -0
- package/flow/steps/index.d.ts.map +1 -1
- package/flow/steps/index.esm.js +3603 -319
- package/flow/steps/index.esm.js.map +1 -1
- package/flow/steps/resolve-repository.d.ts +36 -0
- package/flow/steps/resolve-repository.d.ts.map +1 -0
- package/flow/steps/update-packages.d.ts.map +1 -1
- package/git/factory.d.ts +14 -0
- package/git/factory.d.ts.map +1 -1
- package/git/index.cjs.js +65 -0
- package/git/index.cjs.js.map +1 -1
- package/git/index.esm.js +66 -2
- package/git/index.esm.js.map +1 -1
- package/git/operations/index.cjs.js +40 -0
- package/git/operations/index.cjs.js.map +1 -1
- package/git/operations/index.d.ts +1 -1
- package/git/operations/index.d.ts.map +1 -1
- package/git/operations/index.esm.js +41 -2
- package/git/operations/index.esm.js.map +1 -1
- package/git/operations/log.d.ts +23 -0
- package/git/operations/log.d.ts.map +1 -1
- package/index.cjs.js +6962 -4413
- package/index.cjs.js.map +1 -1
- package/index.esm.js +6964 -4415
- package/index.esm.js.map +1 -1
- package/package.json +26 -1
- package/registry/index.cjs.js +3 -3
- package/registry/index.cjs.js.map +1 -1
- package/registry/index.esm.js +3 -3
- package/registry/index.esm.js.map +1 -1
- package/registry/models/index.cjs.js +2 -0
- package/registry/models/index.cjs.js.map +1 -1
- package/registry/models/index.esm.js +2 -0
- package/registry/models/index.esm.js.map +1 -1
- package/registry/models/version-info.d.ts +10 -0
- package/registry/models/version-info.d.ts.map +1 -1
- package/registry/npm/client.d.ts.map +1 -1
- package/registry/npm/index.cjs.js +1 -3
- package/registry/npm/index.cjs.js.map +1 -1
- package/registry/npm/index.esm.js +1 -3
- package/registry/npm/index.esm.js.map +1 -1
- package/repository/index.cjs.js +998 -0
- package/repository/index.cjs.js.map +1 -0
- package/repository/index.d.ts +4 -0
- package/repository/index.d.ts.map +1 -0
- package/repository/index.esm.js +981 -0
- package/repository/index.esm.js.map +1 -0
- package/repository/models/index.cjs.js +301 -0
- package/repository/models/index.cjs.js.map +1 -0
- package/repository/models/index.d.ts +7 -0
- package/repository/models/index.d.ts.map +1 -0
- package/repository/models/index.esm.js +290 -0
- package/repository/models/index.esm.js.map +1 -0
- package/repository/models/platform.d.ts +58 -0
- package/repository/models/platform.d.ts.map +1 -0
- package/repository/models/repository-config.d.ts +132 -0
- package/repository/models/repository-config.d.ts.map +1 -0
- package/repository/models/resolution.d.ts +121 -0
- package/repository/models/resolution.d.ts.map +1 -0
- package/repository/parse/index.cjs.js +755 -0
- package/repository/parse/index.cjs.js.map +1 -0
- package/repository/parse/index.d.ts +5 -0
- package/repository/parse/index.d.ts.map +1 -0
- package/repository/parse/index.esm.js +749 -0
- package/repository/parse/index.esm.js.map +1 -0
- package/repository/parse/package-json.d.ts +100 -0
- package/repository/parse/package-json.d.ts.map +1 -0
- package/repository/parse/url.d.ts +81 -0
- package/repository/parse/url.d.ts.map +1 -0
- package/repository/url/compare.d.ts +84 -0
- package/repository/url/compare.d.ts.map +1 -0
- package/repository/url/index.cjs.js +178 -0
- package/repository/url/index.cjs.js.map +1 -0
- package/repository/url/index.d.ts +3 -0
- package/repository/url/index.d.ts.map +1 -0
- package/repository/url/index.esm.js +176 -0
- package/repository/url/index.esm.js.map +1 -0
- package/workspace/discovery/index.cjs.js +324 -330
- package/workspace/discovery/index.cjs.js.map +1 -1
- package/workspace/discovery/index.esm.js +324 -330
- package/workspace/discovery/index.esm.js.map +1 -1
- package/workspace/discovery/packages.d.ts +0 -6
- package/workspace/discovery/packages.d.ts.map +1 -1
- package/workspace/index.cjs.js +0 -6
- package/workspace/index.cjs.js.map +1 -1
- package/workspace/index.esm.js +0 -6
- package/workspace/index.esm.js.map +1 -1
package/flow/models/index.cjs.js
CHANGED
|
@@ -1,5 +1,128 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* Safe copies of Set built-in via factory function.
|
|
5
|
+
*
|
|
6
|
+
* Since constructors cannot be safely captured via Object.assign, this module
|
|
7
|
+
* provides a factory function that uses Reflect.construct internally.
|
|
8
|
+
*
|
|
9
|
+
* These references are captured at module initialization time to protect against
|
|
10
|
+
* prototype pollution attacks. Import only what you need for tree-shaking.
|
|
11
|
+
*
|
|
12
|
+
* @module @hyperfrontend/immutable-api-utils/built-in-copy/set
|
|
13
|
+
*/
|
|
14
|
+
// Capture references at module initialization time
|
|
15
|
+
const _Set = globalThis.Set;
|
|
16
|
+
const _Reflect = globalThis.Reflect;
|
|
17
|
+
/**
|
|
18
|
+
* (Safe copy) Creates a new Set using the captured Set constructor.
|
|
19
|
+
* Use this instead of `new Set()`.
|
|
20
|
+
*
|
|
21
|
+
* @param iterable - Optional iterable of values.
|
|
22
|
+
* @returns A new Set instance.
|
|
23
|
+
*/
|
|
24
|
+
const createSet = (iterable) => _Reflect.construct(_Set, iterable ? [iterable] : []);
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Default scopes to exclude from changelogs.
|
|
28
|
+
*
|
|
29
|
+
* These represent repository-level or infrastructure changes
|
|
30
|
+
* that typically don't belong in individual project changelogs.
|
|
31
|
+
*/
|
|
32
|
+
const DEFAULT_EXCLUDE_SCOPES = ['release', 'deps', 'workspace', 'root', 'repo', 'ci', 'build'];
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Creates a matcher that checks if commit scope matches any of the given scopes.
|
|
36
|
+
*
|
|
37
|
+
* @param scopes - Scopes to match against (case-insensitive)
|
|
38
|
+
* @returns Matcher that returns true if scope matches
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* const matcher = scopeMatcher(['ci', 'build', 'tooling'])
|
|
42
|
+
* matcher({ scope: 'CI', ... }) // true
|
|
43
|
+
* matcher({ scope: 'feat', ... }) // false
|
|
44
|
+
*/
|
|
45
|
+
function scopeMatcher(scopes) {
|
|
46
|
+
const normalizedScopes = createSet(scopes.map((s) => s.toLowerCase()));
|
|
47
|
+
return (ctx) => {
|
|
48
|
+
if (!ctx.scope)
|
|
49
|
+
return false;
|
|
50
|
+
return normalizedScopes.has(ctx.scope.toLowerCase());
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Creates a matcher that checks if commit scope starts with any of the given prefixes.
|
|
55
|
+
*
|
|
56
|
+
* @param prefixes - Scope prefixes to match (case-insensitive)
|
|
57
|
+
* @returns Matcher that returns true if scope starts with any prefix
|
|
58
|
+
*
|
|
59
|
+
* @example
|
|
60
|
+
* const matcher = scopePrefixMatcher(['tool-', 'infra-'])
|
|
61
|
+
* matcher({ scope: 'tool-package', ... }) // true
|
|
62
|
+
* matcher({ scope: 'lib-utils', ... }) // false
|
|
63
|
+
*/
|
|
64
|
+
function scopePrefixMatcher(prefixes) {
|
|
65
|
+
const normalizedPrefixes = prefixes.map((p) => p.toLowerCase());
|
|
66
|
+
return (ctx) => {
|
|
67
|
+
if (!ctx.scope)
|
|
68
|
+
return false;
|
|
69
|
+
const normalizedScope = ctx.scope.toLowerCase();
|
|
70
|
+
return normalizedPrefixes.some((prefix) => normalizedScope.startsWith(prefix));
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Combines matchers with OR logic - returns true if ANY matcher matches.
|
|
75
|
+
*
|
|
76
|
+
* @param matchers - Matchers to combine
|
|
77
|
+
* @returns Combined matcher
|
|
78
|
+
*
|
|
79
|
+
* @example
|
|
80
|
+
* const combined = anyOf(
|
|
81
|
+
* scopeMatcher(['ci', 'build']),
|
|
82
|
+
* messageMatcher(['[infra]']),
|
|
83
|
+
* custom((ctx) => ctx.scope?.startsWith('tool-'))
|
|
84
|
+
* )
|
|
85
|
+
*/
|
|
86
|
+
function anyOf(...matchers) {
|
|
87
|
+
return (ctx) => matchers.some((matcher) => matcher(ctx));
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* Matches common CI/CD scopes.
|
|
91
|
+
*
|
|
92
|
+
* Matches: ci, cd, build, pipeline, workflow, actions
|
|
93
|
+
*/
|
|
94
|
+
const CI_SCOPE_MATCHER = scopeMatcher(['ci', 'cd', 'build', 'pipeline', 'workflow', 'actions']);
|
|
95
|
+
/**
|
|
96
|
+
* Matches common tooling/workspace scopes.
|
|
97
|
+
*
|
|
98
|
+
* Matches: tooling, workspace, monorepo, nx, root
|
|
99
|
+
*/
|
|
100
|
+
const TOOLING_SCOPE_MATCHER = scopeMatcher(['tooling', 'workspace', 'monorepo', 'nx', 'root']);
|
|
101
|
+
/**
|
|
102
|
+
* Matches tool-prefixed scopes (e.g., tool-package, tool-scripts).
|
|
103
|
+
*/
|
|
104
|
+
const TOOL_PREFIX_MATCHER = scopePrefixMatcher(['tool-']);
|
|
105
|
+
/**
|
|
106
|
+
* Combined matcher for common infrastructure patterns.
|
|
107
|
+
*
|
|
108
|
+
* Combines CI, tooling, and tool-prefix matchers.
|
|
109
|
+
*/
|
|
110
|
+
anyOf(CI_SCOPE_MATCHER, TOOLING_SCOPE_MATCHER, TOOL_PREFIX_MATCHER);
|
|
111
|
+
|
|
112
|
+
/**
|
|
113
|
+
* Default scope filtering configuration.
|
|
114
|
+
*
|
|
115
|
+
* Uses DEFAULT_EXCLUDE_SCOPES from commits/classify to ensure consistency
|
|
116
|
+
* between flow-level filtering and commit classification.
|
|
117
|
+
*/
|
|
118
|
+
const DEFAULT_SCOPE_FILTERING_CONFIG = {
|
|
119
|
+
strategy: 'hybrid',
|
|
120
|
+
includeScopes: [],
|
|
121
|
+
excludeScopes: DEFAULT_EXCLUDE_SCOPES,
|
|
122
|
+
trackDependencyChanges: false,
|
|
123
|
+
infrastructure: undefined,
|
|
124
|
+
infrastructureMatcher: undefined,
|
|
125
|
+
};
|
|
3
126
|
/**
|
|
4
127
|
* Default flow configuration values.
|
|
5
128
|
*/
|
|
@@ -20,6 +143,8 @@ const DEFAULT_FLOW_CONFIG = {
|
|
|
20
143
|
allowPrerelease: false,
|
|
21
144
|
prereleaseId: 'alpha',
|
|
22
145
|
releaseAs: undefined,
|
|
146
|
+
repository: undefined,
|
|
147
|
+
scopeFiltering: DEFAULT_SCOPE_FILTERING_CONFIG,
|
|
23
148
|
};
|
|
24
149
|
|
|
25
150
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs.js","sources":["../../../../../../../../../../libs/versioning/src/flow/models/types.ts","../../../../../../../../../../libs/versioning/src/flow/models/step.ts","../../../../../../../../../../libs/versioning/src/flow/models/flow.ts"],"sourcesContent":[null,null,null],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"index.cjs.js","sources":["../../../../../../../../../../libs/utils/immutable-api/src/built-in-copy/set/index.ts","../../../../../../../../../../libs/versioning/src/commits/classify/project-scopes.ts","../../../../../../../../../../libs/versioning/src/commits/classify/infrastructure.ts","../../../../../../../../../../libs/versioning/src/flow/models/types.ts","../../../../../../../../../../libs/versioning/src/flow/models/step.ts","../../../../../../../../../../libs/versioning/src/flow/models/flow.ts"],"sourcesContent":[null,null,null,null,null,null],"names":[],"mappings":";;AAAA;;;;;;;;;;AAUG;AAEH;AACA,MAAM,IAAI,GAAG,UAAU,CAAC,GAAG;AAC3B,MAAM,QAAQ,GAAG,UAAU,CAAC,OAAO;AAGnC;;;;;;AAMG;AACI,MAAM,SAAS,GAAG,CAAI,QAA6B,KAAqB,QAAQ,CAAC,SAAS,CAAC,IAAI,EAAE,QAAQ,GAAG,CAAC,QAAQ,CAAC,GAAG,EAAE,CAAC;;ACoInI;;;;;AAKG;AACI,MAAM,sBAAsB,GAAsB,CAAC,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,CAAC;;ACtFxH;;;;;;;;;;AAUG;AACG,SAAU,YAAY,CAAC,MAAyB,EAAA;AACpD,IAAA,MAAM,gBAAgB,GAAG,SAAS,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,WAAW,EAAE,CAAC,CAAC;IACtE,OAAO,CAAC,GAAG,KAAI;QACb,IAAI,CAAC,GAAG,CAAC,KAAK;AAAE,YAAA,OAAO,KAAK;QAC5B,OAAO,gBAAgB,CAAC,GAAG,CAAC,GAAG,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC;AACtD,IAAA,CAAC;AACH;AAEA;;;;;;;;;;AAUG;AACG,SAAU,kBAAkB,CAAC,QAA2B,EAAA;AAC5D,IAAA,MAAM,kBAAkB,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,WAAW,EAAE,CAAC;IAC/D,OAAO,CAAC,GAAG,KAAI;QACb,IAAI,CAAC,GAAG,CAAC,KAAK;AAAE,YAAA,OAAO,KAAK;QAC5B,MAAM,eAAe,GAAG,GAAG,CAAC,KA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CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,MAAM,CAAC;AAChD;AAEA;;;;;;AAMG;AACG,SAAU,OAAO,CAAC,IAAiB,EAAE,MAAc,EAAA;AACvD,IAAA,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,MAAM,CAAC;AAChD;;;;;;;;;;;;;;;;;;;"}
|
package/flow/models/index.esm.js
CHANGED
|
@@ -1,3 +1,126 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Safe copies of Set built-in via factory function.
|
|
3
|
+
*
|
|
4
|
+
* Since constructors cannot be safely captured via Object.assign, this module
|
|
5
|
+
* provides a factory function that uses Reflect.construct internally.
|
|
6
|
+
*
|
|
7
|
+
* These references are captured at module initialization time to protect against
|
|
8
|
+
* prototype pollution attacks. Import only what you need for tree-shaking.
|
|
9
|
+
*
|
|
10
|
+
* @module @hyperfrontend/immutable-api-utils/built-in-copy/set
|
|
11
|
+
*/
|
|
12
|
+
// Capture references at module initialization time
|
|
13
|
+
const _Set = globalThis.Set;
|
|
14
|
+
const _Reflect = globalThis.Reflect;
|
|
15
|
+
/**
|
|
16
|
+
* (Safe copy) Creates a new Set using the captured Set constructor.
|
|
17
|
+
* Use this instead of `new Set()`.
|
|
18
|
+
*
|
|
19
|
+
* @param iterable - Optional iterable of values.
|
|
20
|
+
* @returns A new Set instance.
|
|
21
|
+
*/
|
|
22
|
+
const createSet = (iterable) => _Reflect.construct(_Set, iterable ? [iterable] : []);
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Default scopes to exclude from changelogs.
|
|
26
|
+
*
|
|
27
|
+
* These represent repository-level or infrastructure changes
|
|
28
|
+
* that typically don't belong in individual project changelogs.
|
|
29
|
+
*/
|
|
30
|
+
const DEFAULT_EXCLUDE_SCOPES = ['release', 'deps', 'workspace', 'root', 'repo', 'ci', 'build'];
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Creates a matcher that checks if commit scope matches any of the given scopes.
|
|
34
|
+
*
|
|
35
|
+
* @param scopes - Scopes to match against (case-insensitive)
|
|
36
|
+
* @returns Matcher that returns true if scope matches
|
|
37
|
+
*
|
|
38
|
+
* @example
|
|
39
|
+
* const matcher = scopeMatcher(['ci', 'build', 'tooling'])
|
|
40
|
+
* matcher({ scope: 'CI', ... }) // true
|
|
41
|
+
* matcher({ scope: 'feat', ... }) // false
|
|
42
|
+
*/
|
|
43
|
+
function scopeMatcher(scopes) {
|
|
44
|
+
const normalizedScopes = createSet(scopes.map((s) => s.toLowerCase()));
|
|
45
|
+
return (ctx) => {
|
|
46
|
+
if (!ctx.scope)
|
|
47
|
+
return false;
|
|
48
|
+
return normalizedScopes.has(ctx.scope.toLowerCase());
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Creates a matcher that checks if commit scope starts with any of the given prefixes.
|
|
53
|
+
*
|
|
54
|
+
* @param prefixes - Scope prefixes to match (case-insensitive)
|
|
55
|
+
* @returns Matcher that returns true if scope starts with any prefix
|
|
56
|
+
*
|
|
57
|
+
* @example
|
|
58
|
+
* const matcher = scopePrefixMatcher(['tool-', 'infra-'])
|
|
59
|
+
* matcher({ scope: 'tool-package', ... }) // true
|
|
60
|
+
* matcher({ scope: 'lib-utils', ... }) // false
|
|
61
|
+
*/
|
|
62
|
+
function scopePrefixMatcher(prefixes) {
|
|
63
|
+
const normalizedPrefixes = prefixes.map((p) => p.toLowerCase());
|
|
64
|
+
return (ctx) => {
|
|
65
|
+
if (!ctx.scope)
|
|
66
|
+
return false;
|
|
67
|
+
const normalizedScope = ctx.scope.toLowerCase();
|
|
68
|
+
return normalizedPrefixes.some((prefix) => normalizedScope.startsWith(prefix));
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
/**
|
|
72
|
+
* Combines matchers with OR logic - returns true if ANY matcher matches.
|
|
73
|
+
*
|
|
74
|
+
* @param matchers - Matchers to combine
|
|
75
|
+
* @returns Combined matcher
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* const combined = anyOf(
|
|
79
|
+
* scopeMatcher(['ci', 'build']),
|
|
80
|
+
* messageMatcher(['[infra]']),
|
|
81
|
+
* custom((ctx) => ctx.scope?.startsWith('tool-'))
|
|
82
|
+
* )
|
|
83
|
+
*/
|
|
84
|
+
function anyOf(...matchers) {
|
|
85
|
+
return (ctx) => matchers.some((matcher) => matcher(ctx));
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Matches common CI/CD scopes.
|
|
89
|
+
*
|
|
90
|
+
* Matches: ci, cd, build, pipeline, workflow, actions
|
|
91
|
+
*/
|
|
92
|
+
const CI_SCOPE_MATCHER = scopeMatcher(['ci', 'cd', 'build', 'pipeline', 'workflow', 'actions']);
|
|
93
|
+
/**
|
|
94
|
+
* Matches common tooling/workspace scopes.
|
|
95
|
+
*
|
|
96
|
+
* Matches: tooling, workspace, monorepo, nx, root
|
|
97
|
+
*/
|
|
98
|
+
const TOOLING_SCOPE_MATCHER = scopeMatcher(['tooling', 'workspace', 'monorepo', 'nx', 'root']);
|
|
99
|
+
/**
|
|
100
|
+
* Matches tool-prefixed scopes (e.g., tool-package, tool-scripts).
|
|
101
|
+
*/
|
|
102
|
+
const TOOL_PREFIX_MATCHER = scopePrefixMatcher(['tool-']);
|
|
103
|
+
/**
|
|
104
|
+
* Combined matcher for common infrastructure patterns.
|
|
105
|
+
*
|
|
106
|
+
* Combines CI, tooling, and tool-prefix matchers.
|
|
107
|
+
*/
|
|
108
|
+
anyOf(CI_SCOPE_MATCHER, TOOLING_SCOPE_MATCHER, TOOL_PREFIX_MATCHER);
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* Default scope filtering configuration.
|
|
112
|
+
*
|
|
113
|
+
* Uses DEFAULT_EXCLUDE_SCOPES from commits/classify to ensure consistency
|
|
114
|
+
* between flow-level filtering and commit classification.
|
|
115
|
+
*/
|
|
116
|
+
const DEFAULT_SCOPE_FILTERING_CONFIG = {
|
|
117
|
+
strategy: 'hybrid',
|
|
118
|
+
includeScopes: [],
|
|
119
|
+
excludeScopes: DEFAULT_EXCLUDE_SCOPES,
|
|
120
|
+
trackDependencyChanges: false,
|
|
121
|
+
infrastructure: undefined,
|
|
122
|
+
infrastructureMatcher: undefined,
|
|
123
|
+
};
|
|
1
124
|
/**
|
|
2
125
|
* Default flow configuration values.
|
|
3
126
|
*/
|
|
@@ -18,6 +141,8 @@ const DEFAULT_FLOW_CONFIG = {
|
|
|
18
141
|
allowPrerelease: false,
|
|
19
142
|
prereleaseId: 'alpha',
|
|
20
143
|
releaseAs: undefined,
|
|
144
|
+
repository: undefined,
|
|
145
|
+
scopeFiltering: DEFAULT_SCOPE_FILTERING_CONFIG,
|
|
21
146
|
};
|
|
22
147
|
|
|
23
148
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":["../../../../../../../../../../libs/versioning/src/flow/models/types.ts","../../../../../../../../../../libs/versioning/src/flow/models/step.ts","../../../../../../../../../../libs/versioning/src/flow/models/flow.ts"],"sourcesContent":[null,null,null],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":["../../../../../../../../../../libs/utils/immutable-api/src/built-in-copy/set/index.ts","../../../../../../../../../../libs/versioning/src/commits/classify/project-scopes.ts","../../../../../../../../../../libs/versioning/src/commits/classify/infrastructure.ts","../../../../../../../../../../libs/versioning/src/flow/models/types.ts","../../../../../../../../../../libs/versioning/src/flow/models/step.ts","../../../../../../../../../../libs/versioning/src/flow/models/flow.ts"],"sourcesContent":[null,null,null,null,null,null],"names":[],"mappings":"AAAA;;;;;;;;;;AAUG;AAEH;AACA,MAAM,IAAI,GAAG,UAAU,CAAC,GAAG;AAC3B,MAAM,QAAQ,GAAG,UAAU,CAAC,OAAO;AAGnC;;;;;;AAMG;AACI,MAAM,SAAS,GAAG,CAAI,QAA6B,KAAqB,QAAQ,CAAC,SAAS,CAAC,IAAI,EAAE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ACtF,IAAA,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,YAAY,CAAC;AAChE,IAAA,IAAI,KAAK,KAAK,EAAE,EAAE;;QAEhB,OAAO,UAAU,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;IAClC;IACA,OAAO,UAAU,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,CAAC;AACtC;AAEA;;;;;;;AAOG;SACa,WAAW,CAAC,IAAiB,EAAE,MAAc,EAAE,OAAiB,EAAA;IAC9E,OAAO;AACL,QAAA,GAAG,IAAI;QACP,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,EAAE,KAAK,MAAM,GAAG,OAAO,GAAG,CAAC,CAAC,CAAC;KAC9D;AACH;AAEA;;;;;;AAMG;AACG,SAAU,UAAU,CAAC,IAAiB,EAAE,MAA2B,EAAA;IACvE,OAAO;AACL,QAAA,GAAG,IAAI;QACP,MAAM,EAAE,EAAE,GAAG,IAAI,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE;KACtC;AACH;AAEA;;;;;;AAMG;AACG,SAAU,OAAO,CAAC,IAAiB,EAAE,MAAc,EAAA;AACvD,IAAA,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,MAAM,CAAC;AAChD;AAEA;;;;;;AAMG;AACG,SAAU,OAAO,CAAC,IAAiB,EAAE,MAAc,EAAA;AACvD,IAAA,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,MAAM,CAAC;AAChD;;;;"}
|
package/flow/models/types.d.ts
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import type { Logger } from '@hyperfrontend/logging';
|
|
2
2
|
import type { Tree } from '@hyperfrontend/project-scope';
|
|
3
3
|
import type { ChangelogEntry } from '../../changelog/models/entry';
|
|
4
|
+
import type { ClassificationResult, InfrastructureConfig, InfrastructureMatcher } from '../../commits/classify';
|
|
4
5
|
import type { ConventionalCommit } from '../../commits/models/conventional';
|
|
5
6
|
import type { GitClient } from '../../git/factory';
|
|
6
7
|
import type { Registry } from '../../registry/models/registry';
|
|
8
|
+
import type { RepositoryConfig, RepositoryResolution } from '../../repository/models';
|
|
7
9
|
import type { BumpType } from '../../semver/models/version';
|
|
8
10
|
export type { Logger } from '@hyperfrontend/logging';
|
|
9
11
|
/**
|
|
@@ -15,14 +17,24 @@ export interface FlowState {
|
|
|
15
17
|
readonly currentVersion?: string;
|
|
16
18
|
/** Published version on registry (null if never published) */
|
|
17
19
|
readonly publishedVersion?: string | null;
|
|
20
|
+
/** Git commit hash of the last published version */
|
|
21
|
+
readonly publishedCommit?: string | null;
|
|
18
22
|
/** Calculated next version */
|
|
19
23
|
readonly nextVersion?: string;
|
|
20
24
|
/** Bump type (major/minor/patch/none) */
|
|
21
25
|
readonly bumpType?: BumpType;
|
|
22
26
|
/** Analyzed commits since last release */
|
|
23
27
|
readonly commits?: readonly ConventionalCommit[];
|
|
24
|
-
/**
|
|
25
|
-
readonly
|
|
28
|
+
/** Classification result with source attribution (when scope filtering enabled) */
|
|
29
|
+
readonly classificationResult?: ClassificationResult;
|
|
30
|
+
/**
|
|
31
|
+
* The verified base commit used for commit scoping and changelog generation.
|
|
32
|
+
* This will be `publishedCommit` if that commit is reachable from HEAD,
|
|
33
|
+
* or `null` if a fallback was used (e.g., history was rewritten).
|
|
34
|
+
*
|
|
35
|
+
* When null, compare URLs are omitted from the changelog.
|
|
36
|
+
*/
|
|
37
|
+
readonly effectiveBaseCommit?: string | null;
|
|
26
38
|
/** Generated changelog entry */
|
|
27
39
|
readonly changelogEntry?: ChangelogEntry;
|
|
28
40
|
/** Files modified during flow execution */
|
|
@@ -33,9 +45,124 @@ export interface FlowState {
|
|
|
33
45
|
readonly tagName?: string;
|
|
34
46
|
/** Whether this is a first release (no prior versions) */
|
|
35
47
|
readonly isFirstRelease?: boolean;
|
|
48
|
+
/** Repository configuration for compare URL generation */
|
|
49
|
+
readonly repositoryConfig?: RepositoryConfig;
|
|
50
|
+
/**
|
|
51
|
+
* Whether this is a pending publication scenario.
|
|
52
|
+
* True when currentVersion > publishedVersion, meaning the version
|
|
53
|
+
* was already bumped but not yet published to the registry.
|
|
54
|
+
* When true:
|
|
55
|
+
* - nextVersion is calculated from publishedVersion (not currentVersion)
|
|
56
|
+
* - Changelog entries > publishedVersion should be cleaned up
|
|
57
|
+
* - The correct changelog entry replaces any stacked ones
|
|
58
|
+
*/
|
|
59
|
+
readonly isPendingPublication?: boolean;
|
|
36
60
|
/** Additional custom state for extensibility */
|
|
37
61
|
readonly [key: string]: unknown;
|
|
38
62
|
}
|
|
63
|
+
/**
|
|
64
|
+
* Strategy for filtering commits to a project's changelog.
|
|
65
|
+
*
|
|
66
|
+
* - `'hybrid'`: Use scope + file validation (default, recommended)
|
|
67
|
+
* - `'scope-only'`: Only use scope matching (fast, for disciplined teams)
|
|
68
|
+
* - `'file-only'`: Only use file-based filtering (for non-scoped repos)
|
|
69
|
+
* - `'inferred'`: Auto-detect from commit history
|
|
70
|
+
*/
|
|
71
|
+
export type ScopeFilteringStrategy = 'hybrid' | 'scope-only' | 'file-only' | 'inferred';
|
|
72
|
+
/**
|
|
73
|
+
* Scope filtering configuration.
|
|
74
|
+
*
|
|
75
|
+
* By default, hybrid filtering is enabled universally.
|
|
76
|
+
* Configuration exists for edge cases and external codebases.
|
|
77
|
+
*/
|
|
78
|
+
export interface ScopeFilteringConfig {
|
|
79
|
+
/**
|
|
80
|
+
* Filtering strategy.
|
|
81
|
+
*
|
|
82
|
+
* @default 'hybrid'
|
|
83
|
+
*/
|
|
84
|
+
readonly strategy?: ScopeFilteringStrategy;
|
|
85
|
+
/**
|
|
86
|
+
* Additional scopes to include as direct commits.
|
|
87
|
+
* Use for shared library scopes that should appear in multiple projects.
|
|
88
|
+
*
|
|
89
|
+
* @example ['shared-utils', 'common']
|
|
90
|
+
*/
|
|
91
|
+
readonly includeScopes?: readonly string[];
|
|
92
|
+
/**
|
|
93
|
+
* Scopes to explicitly exclude even if files match.
|
|
94
|
+
* Use for infrastructure scopes that affect build but aren't "changes".
|
|
95
|
+
*
|
|
96
|
+
* @example ['deps', 'release']
|
|
97
|
+
*/
|
|
98
|
+
readonly excludeScopes?: readonly string[];
|
|
99
|
+
/**
|
|
100
|
+
* Include commits that touch dependency packages.
|
|
101
|
+
* When true, changes to dependencies appear as indirect commits.
|
|
102
|
+
*
|
|
103
|
+
* @default false
|
|
104
|
+
*/
|
|
105
|
+
readonly trackDependencyChanges?: boolean;
|
|
106
|
+
/**
|
|
107
|
+
* Infrastructure tracking configuration.
|
|
108
|
+
*
|
|
109
|
+
* Defines how to detect commits that affect build/tooling infrastructure.
|
|
110
|
+
* Supports multiple detection methods:
|
|
111
|
+
* - `paths`: File paths to track via git queries
|
|
112
|
+
* - `scopes`: Conventional commit scopes to match
|
|
113
|
+
* - `matcher`: Custom matching logic
|
|
114
|
+
*
|
|
115
|
+
* All methods are combined with OR logic.
|
|
116
|
+
*
|
|
117
|
+
* @example
|
|
118
|
+
* // Simple path-based
|
|
119
|
+
* infrastructure: { paths: ['tools/', '.github/workflows/'] }
|
|
120
|
+
*
|
|
121
|
+
* @example
|
|
122
|
+
* // Scope-based
|
|
123
|
+
* infrastructure: { scopes: ['ci', 'build', 'tooling'] }
|
|
124
|
+
*
|
|
125
|
+
* @example
|
|
126
|
+
* // Composable matcher
|
|
127
|
+
* import { anyOf, scopeMatcher, scopePrefixMatcher } from '@hyperfrontend/versioning'
|
|
128
|
+
* infrastructure: {
|
|
129
|
+
* paths: ['tools/'],
|
|
130
|
+
* matcher: anyOf(
|
|
131
|
+
* scopeMatcher(['ci', 'build']),
|
|
132
|
+
* scopePrefixMatcher(['tool-'])
|
|
133
|
+
* )
|
|
134
|
+
* }
|
|
135
|
+
*/
|
|
136
|
+
readonly infrastructure?: InfrastructureConfig;
|
|
137
|
+
/**
|
|
138
|
+
* Custom infrastructure matcher function.
|
|
139
|
+
*
|
|
140
|
+
* Provides full programmatic control over infrastructure detection.
|
|
141
|
+
* Takes precedence over `infrastructure` config if both provided.
|
|
142
|
+
*
|
|
143
|
+
* @example
|
|
144
|
+
* infrastructureMatcher: (ctx) => {
|
|
145
|
+
* // Match CI scopes
|
|
146
|
+
* if (ctx.scope === 'ci' || ctx.scope === 'build') return true
|
|
147
|
+
* // Match tool-prefixed scopes
|
|
148
|
+
* if (ctx.scope?.startsWith('tool-')) return true
|
|
149
|
+
* // Match workspace commits during major refactors
|
|
150
|
+
* if (ctx.message.includes('[infra]')) return true
|
|
151
|
+
* return false
|
|
152
|
+
* }
|
|
153
|
+
*/
|
|
154
|
+
readonly infrastructureMatcher?: InfrastructureMatcher;
|
|
155
|
+
}
|
|
156
|
+
/**
|
|
157
|
+
* Default scope filtering configuration.
|
|
158
|
+
*
|
|
159
|
+
* Uses DEFAULT_EXCLUDE_SCOPES from commits/classify to ensure consistency
|
|
160
|
+
* between flow-level filtering and commit classification.
|
|
161
|
+
*/
|
|
162
|
+
export declare const DEFAULT_SCOPE_FILTERING_CONFIG: Required<Omit<ScopeFilteringConfig, 'infrastructure' | 'infrastructureMatcher'>> & {
|
|
163
|
+
infrastructure: undefined;
|
|
164
|
+
infrastructureMatcher: undefined;
|
|
165
|
+
};
|
|
39
166
|
/**
|
|
40
167
|
* Flow configuration options.
|
|
41
168
|
*/
|
|
@@ -72,11 +199,29 @@ export interface FlowConfig {
|
|
|
72
199
|
readonly prereleaseId?: string;
|
|
73
200
|
/** Force a specific bump type, bypassing commit analysis */
|
|
74
201
|
readonly releaseAs?: 'major' | 'minor' | 'patch';
|
|
202
|
+
/**
|
|
203
|
+
* Repository resolution configuration for compare URL generation.
|
|
204
|
+
*
|
|
205
|
+
* Controls how repository information is resolved:
|
|
206
|
+
* - `'disabled'`: No compare URLs generated (default, backward compatible)
|
|
207
|
+
* - `'inferred'`: Auto-detect from package.json or git remote
|
|
208
|
+
* - `RepositoryResolution`: Fine-grained control with explicit mode and options
|
|
209
|
+
* - `RepositoryConfig`: Direct repository configuration
|
|
210
|
+
*/
|
|
211
|
+
readonly repository?: 'disabled' | 'inferred' | RepositoryResolution | RepositoryConfig;
|
|
212
|
+
/**
|
|
213
|
+
* Commit scope filtering configuration.
|
|
214
|
+
* Controls how commits are attributed to projects in changelogs.
|
|
215
|
+
*
|
|
216
|
+
* By default, hybrid filtering ensures commits are included based on
|
|
217
|
+
* conventional commit scope OR file changes within the project.
|
|
218
|
+
*/
|
|
219
|
+
readonly scopeFiltering?: ScopeFilteringConfig;
|
|
75
220
|
}
|
|
76
221
|
/**
|
|
77
222
|
* Default flow configuration values.
|
|
78
223
|
*/
|
|
79
|
-
export declare const DEFAULT_FLOW_CONFIG: Required<FlowConfig>;
|
|
224
|
+
export declare const DEFAULT_FLOW_CONFIG: Required<Omit<FlowConfig, 'repository' | 'scopeFiltering'>> & Pick<FlowConfig, 'repository' | 'scopeFiltering'>;
|
|
80
225
|
/**
|
|
81
226
|
* Execution context passed to each step.
|
|
82
227
|
* Contains all resources and accumulated state.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/versioning/src/flow/models/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAA;AACpD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,8BAA8B,CAAA;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/versioning/src/flow/models/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAA;AACpD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,8BAA8B,CAAA;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,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,QAAQ,CAAC,KAAK,CAAC,EAAE,KAAK,CAAA;CACvB;AAED;;GAEG;AACH,MAAM,WAAW,oBAAqB,SAAQ,cAAc;IAC1D,sBAAsB;IACtB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IAEvB,wBAAwB;IACxB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;CAC1B;AAED;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAAA;AAErE;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,2BAA2B;IAC3B,QAAQ,CAAC,MAAM,EAAE,UAAU,CAAA;IAE3B,4BAA4B;IAC5B,QAAQ,CAAC,KAAK,EAAE,SAAS,oBAAoB,EAAE,CAAA;IAE/C,8BAA8B;IAC9B,QAAQ,CAAC,KAAK,EAAE,SAAS,CAAA;IAEzB,+BAA+B;IAC/B,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IAEzB,sBAAsB;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;CACzB"}
|
|
@@ -9,14 +9,15 @@ export declare const CONVENTIONAL_FLOW_CONFIG: FlowConfig;
|
|
|
9
9
|
*
|
|
10
10
|
* This flow follows the standard conventional commits workflow:
|
|
11
11
|
* 1. Fetch published version from registry
|
|
12
|
-
* 2.
|
|
13
|
-
* 3.
|
|
14
|
-
* 4.
|
|
15
|
-
* 5.
|
|
16
|
-
* 6.
|
|
17
|
-
* 7.
|
|
18
|
-
* 8.
|
|
19
|
-
* 9. Create git
|
|
12
|
+
* 2. Resolve repository configuration (for compare URLs)
|
|
13
|
+
* 3. Analyze commits since last release
|
|
14
|
+
* 4. Calculate version bump based on commit types
|
|
15
|
+
* 5. Check if version already published (idempotency)
|
|
16
|
+
* 6. Generate changelog entry (with compare URL if repository resolved)
|
|
17
|
+
* 7. Update package.json version
|
|
18
|
+
* 8. Write changelog to file
|
|
19
|
+
* 9. Create git commit (optional)
|
|
20
|
+
* 10. Create git tag (optional, typically after publish)
|
|
20
21
|
*
|
|
21
22
|
* @param config - Optional configuration overrides
|
|
22
23
|
* @returns A VersionFlow configured for conventional commits
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conventional.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/versioning/src/flow/presets/conventional.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"conventional.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/versioning/src/flow/presets/conventional.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAejD;;GAEG;AACH,eAAO,MAAM,wBAAwB,EAAE,UAatC,CAAA;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,wBAAgB,sBAAsB,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,GAAG,WAAW,CAuBhF;AAED;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,GAAG,WAAW,CAM3E;AAED;;;;;;;GAOG;AACH,wBAAgB,uBAAuB,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,GAAG,WAAW,CAqBjF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"independent.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/versioning/src/flow/presets/independent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAC9C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"independent.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/versioning/src/flow/presets/independent.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAA;AACjD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAC9C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAkBjD;;GAEG;AACH,eAAO,MAAM,uBAAuB,EAAE,UAIrC,CAAA;AAED;;;;;;;GAOG;AACH,wBAAgB,6BAA6B,IAAI,QAAQ,CAkCxD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAgB,qBAAqB,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,GAAG,WAAW,CAyB/E;AAED;;;;;;;;;GASG;AACH,wBAAgB,sBAAsB,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,GAAG,WAAW,CAwBhF"}
|