git-digger 1.5.43 → 1.5.44

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.
Files changed (64) hide show
  1. package/kotlin/Kotlin-DateTime-library-kotlinx-datetime.js +5104 -0
  2. package/kotlin/Kotlin-DateTime-library-kotlinx-datetime.js.map +1 -0
  3. package/kotlin/bin/digger +0 -0
  4. package/kotlin/clikt-clikt-mordant.js +303 -0
  5. package/kotlin/clikt-clikt-mordant.js.map +1 -0
  6. package/kotlin/clikt-clikt.js +6742 -0
  7. package/kotlin/clikt-clikt.js.map +1 -0
  8. package/kotlin/colormath-root-colormath.js +1627 -0
  9. package/kotlin/colormath-root-colormath.js.map +1 -0
  10. package/kotlin/command-line-tools-digger-cli.js +563 -0
  11. package/kotlin/command-line-tools-digger-cli.js.map +1 -0
  12. package/kotlin/kotlin-kotlin-stdlib.js +11651 -0
  13. package/kotlin/kotlin-kotlin-stdlib.js.map +1 -0
  14. package/kotlin/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js +8 -0
  15. package/kotlin/{kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.mjs.map → kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.js.map} +1 -1
  16. package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js +3509 -0
  17. package/kotlin/kotlinx-serialization-kotlinx-serialization-core.js.map +1 -0
  18. package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js +1118 -0
  19. package/kotlin/kotlinx-serialization-kotlinx-serialization-json.js.map +1 -0
  20. package/kotlin/mordant-mordant-omnibus.js +8 -0
  21. package/kotlin/{mordant-mordant-omnibus.mjs.map → mordant-mordant-omnibus.js.map} +1 -1
  22. package/kotlin/mordant-mordant.js +10271 -0
  23. package/kotlin/mordant-mordant.js.map +1 -0
  24. package/kotlin/tools-cli-tools.js +29 -0
  25. package/kotlin/tools-cli-tools.js.map +1 -0
  26. package/kotlin/tools-digger-core.js +659 -0
  27. package/kotlin/tools-digger-core.js.map +1 -0
  28. package/kotlin/tools-digger-json.js +256 -0
  29. package/kotlin/tools-digger-json.js.map +1 -0
  30. package/kotlin/tools-digger-model.js +107 -0
  31. package/kotlin/tools-digger-model.js.map +1 -0
  32. package/kotlin/tools-git-adapter.js +255 -0
  33. package/kotlin/tools-git-adapter.js.map +1 -0
  34. package/package.json +2 -2
  35. package/kotlin/Kotlin-DateTime-library-kotlinx-datetime.mjs +0 -5119
  36. package/kotlin/Kotlin-DateTime-library-kotlinx-datetime.mjs.map +0 -1
  37. package/kotlin/clikt-clikt-mordant.mjs +0 -310
  38. package/kotlin/clikt-clikt-mordant.mjs.map +0 -1
  39. package/kotlin/clikt-clikt.mjs +0 -6663
  40. package/kotlin/clikt-clikt.mjs.map +0 -1
  41. package/kotlin/colormath-root-colormath.mjs +0 -1675
  42. package/kotlin/colormath-root-colormath.mjs.map +0 -1
  43. package/kotlin/command-line-tools-digger-cli.mjs +0 -498
  44. package/kotlin/command-line-tools-digger-cli.mjs.map +0 -1
  45. package/kotlin/kotlin-kotlin-stdlib.mjs +0 -11790
  46. package/kotlin/kotlin-kotlin-stdlib.mjs.map +0 -1
  47. package/kotlin/kotlin_org_jetbrains_kotlin_kotlin_dom_api_compat.mjs +0 -4
  48. package/kotlin/kotlinx-serialization-kotlinx-serialization-core.mjs +0 -3640
  49. package/kotlin/kotlinx-serialization-kotlinx-serialization-core.mjs.map +0 -1
  50. package/kotlin/kotlinx-serialization-kotlinx-serialization-json.mjs +0 -1140
  51. package/kotlin/kotlinx-serialization-kotlinx-serialization-json.mjs.map +0 -1
  52. package/kotlin/mordant-mordant-omnibus.mjs +0 -4
  53. package/kotlin/mordant-mordant.mjs +0 -10332
  54. package/kotlin/mordant-mordant.mjs.map +0 -1
  55. package/kotlin/tools-cli-tools.mjs +0 -30
  56. package/kotlin/tools-cli-tools.mjs.map +0 -1
  57. package/kotlin/tools-digger-core.mjs +0 -666
  58. package/kotlin/tools-digger-core.mjs.map +0 -1
  59. package/kotlin/tools-digger-json.mjs +0 -263
  60. package/kotlin/tools-digger-json.mjs.map +0 -1
  61. package/kotlin/tools-digger-model.mjs +0 -109
  62. package/kotlin/tools-digger-model.mjs.map +0 -1
  63. package/kotlin/tools-git-adapter.mjs +0 -261
  64. package/kotlin/tools-git-adapter.mjs.map +0 -1
@@ -1,666 +0,0 @@
1
- import {
2
- HashSet2dzve9y63nf0v as HashSet,
3
- ArrayList3it5z8td81qkl as ArrayList,
4
- Unit_instance14hm69wy3kr8u as Unit_instance,
5
- collectionSizeOrDefault36dulx8yinfqm as collectionSizeOrDefault,
6
- to2cs3ny02qtbcb as to,
7
- firstOrNull1982767dljvdy as firstOrNull,
8
- Paire9pteg33gng7 as Pair,
9
- listOfvhqybd2zx248 as listOf,
10
- checkIndexOverflow3frtmheghr0th as checkIndexOverflow,
11
- getOrNull1go7ef9ldk0df as getOrNull,
12
- plus310ted5e4i90h as plus,
13
- emptyList1g2z5xcrvp2zy as emptyList,
14
- plus20p0vtfmu0596 as plus_0,
15
- last1vo29oleiqj36 as last,
16
- toString1pkumu07cwy4m as toString,
17
- toString30pk9tzaqopn as toString_0,
18
- getStringHashCode26igk1bx568vk as getStringHashCode,
19
- hashCodeq5arwsb9dgti as hashCode,
20
- THROW_CCE2g6jy02ryeudk as THROW_CCE,
21
- equals2au1ep9vhcato as equals,
22
- initMetadataForClassbxx6q50dy2s7 as initMetadataForClass,
23
- lastOrNull1aq5oz189qoe1 as lastOrNull,
24
- maxOrNull2e5ok5wkly1cp as maxOrNull,
25
- listOf1jh22dvmctj1r as listOf_0,
26
- addAll1k27qatfgp3k5 as addAll,
27
- toSet2orjxp16sotqu as toSet,
28
- sorted354mfsiv4s7x5 as sorted,
29
- toList3jhuyej2anx2q as toList,
30
- joinToString1cxrrlmo0chqs as joinToString,
31
- Regexxgw0gjiagf4z as Regex,
32
- initMetadataForObject1cxne3s9w65el as initMetadataForObject,
33
- VOID7hggqo3abtya as VOID,
34
- take3onnpy6q7ctcz as take,
35
- RegexOption_IGNORE_CASE_getInstance3gy6kkhlhefwp as RegexOption_IGNORE_CASE_getInstance,
36
- RuntimeException1r3t0zl97011n as RuntimeException,
37
- contains3ue2qo8xhmpf1 as contains,
38
- mapOf1xd03cq9cnmy8 as mapOf,
39
- RegexOption_MULTILINE_getInstance38b3use4ozxws as RegexOption_MULTILINE_getInstance,
40
- setOf45ia9pnfhe90 as setOf,
41
- firstOrNulltrxqttxfxqju as firstOrNull_0,
42
- lastIndexOf2d52xhix5ymjr as lastIndexOf,
43
- Char19o2r8palgjof as Char,
44
- _Char___init__impl__6a9atx367vrx0avsvbg as _Char___init__impl__6a9atx,
45
- mapNotNull3b8ce5hky4k2l as mapNotNull,
46
- toListx6x8nvfmvvht as toList_0,
47
- maxOrNull2yp8rzwwvng8y as maxOrNull_0,
48
- getc6436eumi25w as get,
49
- toIntOrNull3w2d066r9pvwm as toIntOrNull,
50
- Companion_instance1et3290wko23u as Companion_instance,
51
- _Result___init__impl__xyqfz8oelep8i0cbta as _Result___init__impl__xyqfz8,
52
- createFailure8paxfkfa5dc7 as createFailure,
53
- _Result___get_value__impl__bjfvqgbxrwpgk5sesh as _Result___get_value__impl__bjfvqg,
54
- _Result___get_isFailure__impl__jpiriv2jp2gwqhnirp8 as _Result___get_isFailure__impl__jpiriv,
55
- Enum3alwj03lh1n41 as Enum,
56
- } from './kotlin-kotlin-stdlib.mjs';
57
- import { Contribution3ng1h8np97gzb as Contribution } from './tools-digger-model.mjs';
58
- //region block: imports
59
- var imul = Math.imul;
60
- //endregion
61
- //region block: pre-declaration
62
- class CommitInspectionResult {
63
- constructor(storyId, ease, authors, semver) {
64
- this.b1g_1 = storyId;
65
- this.c1g_1 = ease;
66
- this.d1g_1 = authors;
67
- this.e1g_1 = semver;
68
- }
69
- toString() {
70
- return 'CommitInspectionResult(storyId=' + this.b1g_1 + ', ease=' + this.c1g_1 + ', authors=' + toString(this.d1g_1) + ', semver=' + toString_0(this.e1g_1) + ')';
71
- }
72
- hashCode() {
73
- var result = this.b1g_1 == null ? 0 : getStringHashCode(this.b1g_1);
74
- result = imul(result, 31) + (this.c1g_1 == null ? 0 : this.c1g_1) | 0;
75
- result = imul(result, 31) + hashCode(this.d1g_1) | 0;
76
- result = imul(result, 31) + (this.e1g_1 == null ? 0 : this.e1g_1.hashCode()) | 0;
77
- return result;
78
- }
79
- equals(other) {
80
- if (this === other)
81
- return true;
82
- if (!(other instanceof CommitInspectionResult))
83
- return false;
84
- var tmp0_other_with_cast = other instanceof CommitInspectionResult ? other : THROW_CCE();
85
- if (!(this.b1g_1 == tmp0_other_with_cast.b1g_1))
86
- return false;
87
- if (!(this.c1g_1 == tmp0_other_with_cast.c1g_1))
88
- return false;
89
- if (!equals(this.d1g_1, tmp0_other_with_cast.d1g_1))
90
- return false;
91
- if (!equals(this.e1g_1, tmp0_other_with_cast.e1g_1))
92
- return false;
93
- return true;
94
- }
95
- }
96
- class Defaults {
97
- constructor() {
98
- Defaults_instance = this;
99
- this.u1g_1 = Regex.ng('.*');
100
- }
101
- }
102
- class DiggerCore {
103
- constructor(label, gitWrapper, messageDigger, tagRegex) {
104
- tagRegex = tagRegex === VOID ? Defaults_getInstance().u1g_1 : tagRegex;
105
- this.q1g_1 = label;
106
- this.r1g_1 = gitWrapper;
107
- this.s1g_1 = messageDigger;
108
- this.t1g_1 = tagRegex;
109
- }
110
- v1g() {
111
- // Inline function 'kotlin.with' call
112
- // Inline function 'com.zegreatrob.tools.digger.core.DiggerCore.currentContributionData.<anonymous>' call
113
- var $this$with = this.r1g_1;
114
- var _destruct__k2r9zo = currentRelevantTags(this, $this$with.t1f(), take(tagRefs(this), 2));
115
- var currentTag = _destruct__k2r9zo.yd();
116
- var previousTag = _destruct__k2r9zo.zd();
117
- var tmp = contribution(this.s1g_1, currentContributionCommits($this$with, previousTag));
118
- var tmp_0 = currentTag == null ? null : currentTag.y1f_1;
119
- return tmp.i1f(VOID, VOID, VOID, VOID, VOID, VOID, VOID, VOID, VOID, this.q1g_1, tmp_0, currentTag == null ? null : currentTag.a1g_1);
120
- }
121
- w1g() {
122
- // Inline function 'kotlin.collections.map' call
123
- var this_0 = allContributionCommits(this.r1g_1, tagRefs(this), this.r1g_1.v1f());
124
- // Inline function 'kotlin.collections.mapTo' call
125
- var destination = ArrayList.k1(collectionSizeOrDefault(this_0, 10));
126
- var _iterator__ex2g4s = this_0.d1();
127
- while (_iterator__ex2g4s.e1()) {
128
- var item = _iterator__ex2g4s.f1();
129
- // Inline function 'com.zegreatrob.tools.digger.core.DiggerCore.allContributionData.<anonymous>' call
130
- var tmp$ret$0 = to(item.wd_1, contribution(this.s1g_1, toList(item.xd_1)));
131
- destination.o(tmp$ret$0);
132
- }
133
- // Inline function 'kotlin.collections.map' call
134
- // Inline function 'kotlin.collections.mapTo' call
135
- var destination_0 = ArrayList.k1(collectionSizeOrDefault(destination, 10));
136
- var _iterator__ex2g4s_0 = destination.d1();
137
- while (_iterator__ex2g4s_0.e1()) {
138
- var item_0 = _iterator__ex2g4s_0.f1();
139
- // Inline function 'com.zegreatrob.tools.digger.core.DiggerCore.allContributionData.<anonymous>' call
140
- var tag = item_0.yd();
141
- var contribution_0 = item_0.zd();
142
- var tmp = tag == null ? null : tag.y1f_1;
143
- var tmp$ret$3 = contribution_0.i1f(VOID, VOID, VOID, VOID, VOID, VOID, VOID, VOID, VOID, this.q1g_1, tmp, tag == null ? null : tag.a1g_1);
144
- destination_0.o(tmp$ret$3);
145
- }
146
- return destination_0;
147
- }
148
- }
149
- class MessageDigResult {
150
- constructor(storyId, ease, coauthors, semver) {
151
- this.m1g_1 = storyId;
152
- this.n1g_1 = ease;
153
- this.o1g_1 = coauthors;
154
- this.p1g_1 = semver;
155
- }
156
- toString() {
157
- return 'MessageDigResult(storyId=' + this.m1g_1 + ', ease=' + this.n1g_1 + ', coauthors=' + toString(this.o1g_1) + ', semver=' + toString_0(this.p1g_1) + ')';
158
- }
159
- hashCode() {
160
- var result = this.m1g_1 == null ? 0 : getStringHashCode(this.m1g_1);
161
- result = imul(result, 31) + (this.n1g_1 == null ? 0 : this.n1g_1) | 0;
162
- result = imul(result, 31) + hashCode(this.o1g_1) | 0;
163
- result = imul(result, 31) + (this.p1g_1 == null ? 0 : this.p1g_1.hashCode()) | 0;
164
- return result;
165
- }
166
- equals(other) {
167
- if (this === other)
168
- return true;
169
- if (!(other instanceof MessageDigResult))
170
- return false;
171
- var tmp0_other_with_cast = other instanceof MessageDigResult ? other : THROW_CCE();
172
- if (!(this.m1g_1 == tmp0_other_with_cast.m1g_1))
173
- return false;
174
- if (!(this.n1g_1 == tmp0_other_with_cast.n1g_1))
175
- return false;
176
- if (!equals(this.o1g_1, tmp0_other_with_cast.o1g_1))
177
- return false;
178
- if (!equals(this.p1g_1, tmp0_other_with_cast.p1g_1))
179
- return false;
180
- return true;
181
- }
182
- }
183
- class Defaults_0 {
184
- constructor() {
185
- Defaults_instance_0 = this;
186
- this.x1g_1 = Regex.mg('\\[major\\]', RegexOption_IGNORE_CASE_getInstance());
187
- this.y1g_1 = Regex.mg('\\[minor\\]', RegexOption_IGNORE_CASE_getInstance());
188
- this.z1g_1 = Regex.mg('\\[patch\\]', RegexOption_IGNORE_CASE_getInstance());
189
- this.a1h_1 = Regex.mg('\\[none\\]', RegexOption_IGNORE_CASE_getInstance());
190
- this.b1h_1 = Regex.ng('\\[(?<storyId>.*?)\\]');
191
- this.c1h_1 = Regex.ng('-(?<ease>[1-5])-');
192
- }
193
- }
194
- class MessageDigger {
195
- constructor(majorRegex, minorRegex, patchRegex, noneRegex, storyIdRegex, easeRegex) {
196
- majorRegex = majorRegex === VOID ? Defaults_getInstance_0().x1g_1 : majorRegex;
197
- minorRegex = minorRegex === VOID ? Defaults_getInstance_0().y1g_1 : minorRegex;
198
- patchRegex = patchRegex === VOID ? Defaults_getInstance_0().z1g_1 : patchRegex;
199
- noneRegex = noneRegex === VOID ? Defaults_getInstance_0().a1h_1 : noneRegex;
200
- storyIdRegex = storyIdRegex === VOID ? Defaults_getInstance_0().b1h_1 : storyIdRegex;
201
- easeRegex = easeRegex === VOID ? Defaults_getInstance_0().c1h_1 : easeRegex;
202
- if (!contains(storyIdRegex.fg_1, '?<storyId>')) {
203
- throw RuntimeException.t9('StoryIdRegex must include a storyId group. The regex was: ' + storyIdRegex.fg_1);
204
- }
205
- if (!contains(easeRegex.fg_1, '?<ease>')) {
206
- throw RuntimeException.t9('EaseRegex must include an ease group. The regex was: ' + easeRegex.fg_1);
207
- }
208
- this.f1g_1 = mapOf([to('major', majorRegex), to('minor', minorRegex), to('patch', patchRegex), to('none', noneRegex)]);
209
- var tmp = this;
210
- // Inline function 'kotlin.collections.map' call
211
- var this_0 = this.f1g_1;
212
- // Inline function 'kotlin.collections.mapTo' call
213
- var destination = ArrayList.k1(this_0.i1());
214
- // Inline function 'kotlin.collections.iterator' call
215
- var _iterator__ex2g4s = this_0.q1().d1();
216
- while (_iterator__ex2g4s.e1()) {
217
- var item = _iterator__ex2g4s.f1();
218
- // Inline function 'com.zegreatrob.tools.digger.core.MessageDigger.allSemverRegex.<anonymous>' call
219
- // Inline function 'kotlin.collections.component1' call
220
- var group = item.r1();
221
- // Inline function 'kotlin.collections.component2' call
222
- var regex = item.s1();
223
- var tmp$ret$3 = '(?<' + group + '>' + cleaned(regex) + ')?';
224
- destination.o(tmp$ret$3);
225
- }
226
- tmp.g1g_1 = joinToString(destination, '');
227
- this.h1g_1 = '(' + cleaned(storyIdRegex) + ')?';
228
- this.i1g_1 = '(' + cleaned(easeRegex) + ')?';
229
- this.j1g_1 = '(Co-authored-by: .* <(?<coAuthors>.*)>)?';
230
- this.k1g_1 = Regex.lg(this.g1g_1 + this.h1g_1 + this.i1g_1 + this.j1g_1, setOf([RegexOption_IGNORE_CASE_getInstance(), RegexOption_MULTILINE_getInstance()]));
231
- }
232
- l1g(input) {
233
- return messageDigResult(this.k1g_1.rg(input));
234
- }
235
- }
236
- class SemverType extends Enum {}
237
- //endregion
238
- function allContributionCommits(_this__u8e3s4, tagRefs, fullLog) {
239
- // Inline function 'kotlin.collections.distinctBy' call
240
- var set = HashSet.g9();
241
- var list = ArrayList.n();
242
- var _iterator__ex2g4s = tagRefs.d1();
243
- while (_iterator__ex2g4s.e1()) {
244
- var e = _iterator__ex2g4s.f1();
245
- // Inline function 'com.zegreatrob.tools.digger.core.allContributionCommits.<anonymous>' call
246
- var key = e.z1f_1;
247
- if (set.o(key)) {
248
- list.o(e);
249
- }
250
- }
251
- // Inline function 'kotlin.collections.filter' call
252
- // Inline function 'kotlin.collections.filterTo' call
253
- var destination = ArrayList.n();
254
- var _iterator__ex2g4s_0 = list.d1();
255
- while (_iterator__ex2g4s_0.e1()) {
256
- var element = _iterator__ex2g4s_0.f1();
257
- // Inline function 'com.zegreatrob.tools.digger.core.allContributionCommits.<anonymous>' call
258
- // Inline function 'kotlin.collections.map' call
259
- // Inline function 'kotlin.collections.mapTo' call
260
- var destination_0 = ArrayList.k1(collectionSizeOrDefault(fullLog, 10));
261
- var _iterator__ex2g4s_1 = fullLog.d1();
262
- while (_iterator__ex2g4s_1.e1()) {
263
- var item = _iterator__ex2g4s_1.f1();
264
- // Inline function 'com.zegreatrob.tools.digger.core.allContributionCommits.<anonymous>.stub_for_inlining' call
265
- var tmp$ret$2 = item.j1f_1;
266
- destination_0.o(tmp$ret$2);
267
- }
268
- if (destination_0.w1(element.z1f_1)) {
269
- destination.o(element);
270
- }
271
- }
272
- return sortIntoTagSets(_this__u8e3s4, destination, fullLog);
273
- }
274
- function sortIntoTagSets(_this__u8e3s4, tagRefs, log) {
275
- // Inline function 'kotlin.collections.map' call
276
- var this_0 = tagPairs(tagRefs);
277
- // Inline function 'kotlin.collections.mapTo' call
278
- var destination = ArrayList.k1(collectionSizeOrDefault(this_0, 10));
279
- var _iterator__ex2g4s = this_0.d1();
280
- while (_iterator__ex2g4s.e1()) {
281
- var item = _iterator__ex2g4s.f1();
282
- // Inline function 'com.zegreatrob.tools.digger.core.sortIntoTagSets.<anonymous>' call
283
- var earlierTag = item.yd();
284
- var nextTag = item.zd();
285
- var tmp;
286
- if (earlierTag == null && !(nextTag == null)) {
287
- tmp = _this__u8e3s4.w1f('^' + nextTag.z1f_1, 'HEAD');
288
- } else if (!(earlierTag == null) && !(nextTag == null)) {
289
- tmp = _this__u8e3s4.w1f('^' + nextTag.z1f_1, earlierTag.z1f_1);
290
- } else if (!(earlierTag == null)) {
291
- tmp = _this__u8e3s4.x1f(earlierTag.z1f_1);
292
- } else {
293
- tmp = alwaysLeftParent(log);
294
- }
295
- var tmp$ret$0 = to(earlierTag, tmp);
296
- destination.o(tmp$ret$0);
297
- }
298
- // Inline function 'kotlin.collections.filter' call
299
- // Inline function 'kotlin.collections.filterTo' call
300
- var destination_0 = ArrayList.n();
301
- var _iterator__ex2g4s_0 = destination.d1();
302
- while (_iterator__ex2g4s_0.e1()) {
303
- var element = _iterator__ex2g4s_0.f1();
304
- // Inline function 'com.zegreatrob.tools.digger.core.sortIntoTagSets.<anonymous>' call
305
- // Inline function 'kotlin.collections.isNotEmpty' call
306
- if (!element.xd_1.a1()) {
307
- destination_0.o(element);
308
- }
309
- }
310
- return destination_0;
311
- }
312
- function tagPairs(_this__u8e3s4) {
313
- var tmp = listOf(new Pair(null, firstOrNull(_this__u8e3s4)));
314
- // Inline function 'kotlin.collections.mapIndexed' call
315
- // Inline function 'kotlin.collections.mapIndexedTo' call
316
- var destination = ArrayList.k1(collectionSizeOrDefault(_this__u8e3s4, 10));
317
- var index = 0;
318
- var _iterator__ex2g4s = _this__u8e3s4.d1();
319
- while (_iterator__ex2g4s.e1()) {
320
- var item = _iterator__ex2g4s.f1();
321
- var _unary__edvuaz = index;
322
- index = _unary__edvuaz + 1 | 0;
323
- // Inline function 'com.zegreatrob.tools.digger.core.tagPairs.<anonymous>' call
324
- var index_0 = checkIndexOverflow(_unary__edvuaz);
325
- var tmp$ret$0 = to(item, getOrNull(_this__u8e3s4, index_0 + 1 | 0));
326
- destination.o(tmp$ret$0);
327
- }
328
- return plus(tmp, destination);
329
- }
330
- function alwaysLeftParent(_this__u8e3s4) {
331
- // Inline function 'kotlin.collections.fold' call
332
- var accumulator = emptyList();
333
- var _iterator__ex2g4s = _this__u8e3s4.d1();
334
- while (_iterator__ex2g4s.e1()) {
335
- var element = _iterator__ex2g4s.f1();
336
- // Inline function 'com.zegreatrob.tools.digger.core.alwaysLeftParent.<anonymous>' call
337
- var acc = accumulator;
338
- var tmp;
339
- if (acc.a1()) {
340
- tmp = plus_0(acc, element);
341
- } else if (element.j1f_1 === firstOrNull(last(acc).n1f_1)) {
342
- tmp = plus_0(acc, element);
343
- } else {
344
- tmp = acc;
345
- }
346
- accumulator = tmp;
347
- }
348
- return accumulator;
349
- }
350
- function contribution(_this__u8e3s4, commitRefs) {
351
- // Inline function 'kotlin.collections.map' call
352
- // Inline function 'kotlin.collections.mapTo' call
353
- var destination = ArrayList.k1(collectionSizeOrDefault(commitRefs, 10));
354
- var _iterator__ex2g4s = commitRefs.d1();
355
- while (_iterator__ex2g4s.e1()) {
356
- var item = _iterator__ex2g4s.f1();
357
- // Inline function 'com.zegreatrob.tools.digger.core.contribution.<anonymous>' call
358
- var tmp$ret$0 = commitInspectionResult(item, _this__u8e3s4.l1g(item.o1f_1));
359
- destination.o(tmp$ret$0);
360
- }
361
- var messageDigResults = destination;
362
- var lastCommit = firstOrNull(commitRefs);
363
- var firstCommit = lastOrNull(commitRefs);
364
- var tmp1_elvis_lhs = lastCommit == null ? null : lastCommit.j1f_1;
365
- var tmp7_lastCommit = tmp1_elvis_lhs == null ? '' : tmp1_elvis_lhs;
366
- var tmp3_elvis_lhs = firstCommit == null ? null : firstCommit.j1f_1;
367
- var tmp8_firstCommit = tmp3_elvis_lhs == null ? '' : tmp3_elvis_lhs;
368
- var tmp9_authors = allAuthors(messageDigResults);
369
- var tmp10_dateTime = lastCommit == null ? null : lastCommit.m1f_1;
370
- var tmp11_firstCommitDateTime = firstCommit == null ? null : firstCommit.m1f_1;
371
- // Inline function 'kotlin.collections.mapNotNull' call
372
- // Inline function 'kotlin.collections.mapNotNullTo' call
373
- var destination_0 = ArrayList.n();
374
- // Inline function 'kotlin.collections.forEach' call
375
- var _iterator__ex2g4s_0 = messageDigResults.d1();
376
- while (_iterator__ex2g4s_0.e1()) {
377
- var element = _iterator__ex2g4s_0.f1();
378
- // Inline function 'kotlin.collections.mapNotNullTo.<anonymous>' call
379
- // Inline function 'com.zegreatrob.tools.digger.core.contribution.<anonymous>' call
380
- var tmp0_safe_receiver = element.c1g_1;
381
- if (tmp0_safe_receiver == null)
382
- null;
383
- else {
384
- // Inline function 'kotlin.let' call
385
- // Inline function 'kotlin.collections.mapNotNullTo.<anonymous>.<anonymous>' call
386
- destination_0.o(tmp0_safe_receiver);
387
- }
388
- }
389
- var tmp12_ease = maxOrNull(destination_0);
390
- var tmp13_storyId = mergedStoryIds(messageDigResults);
391
- // Inline function 'kotlin.collections.mapNotNull' call
392
- // Inline function 'kotlin.collections.mapNotNullTo' call
393
- var destination_1 = ArrayList.n();
394
- // Inline function 'kotlin.collections.forEach' call
395
- var _iterator__ex2g4s_1 = messageDigResults.d1();
396
- while (_iterator__ex2g4s_1.e1()) {
397
- var element_0 = _iterator__ex2g4s_1.f1();
398
- // Inline function 'kotlin.collections.mapNotNullTo.<anonymous>' call
399
- // Inline function 'com.zegreatrob.tools.digger.core.contribution.<anonymous>' call
400
- var tmp0_safe_receiver_0 = element_0.e1g_1;
401
- if (tmp0_safe_receiver_0 == null)
402
- null;
403
- else {
404
- // Inline function 'kotlin.let' call
405
- // Inline function 'kotlin.collections.mapNotNullTo.<anonymous>.<anonymous>' call
406
- destination_1.o(tmp0_safe_receiver_0);
407
- }
408
- }
409
- var tmp6_safe_receiver = highestPrioritySemver(destination_1);
410
- var tmp14_semver = tmp6_safe_receiver == null ? null : tmp6_safe_receiver.toString();
411
- // Inline function 'kotlin.collections.count' call
412
- var tmp15_commitCount = commitRefs.i1();
413
- return new Contribution(tmp7_lastCommit, tmp8_firstCommit, tmp9_authors, tmp15_commitCount, tmp10_dateTime, tmp11_firstCommitDateTime, tmp12_ease, tmp13_storyId, tmp14_semver, null, null, null);
414
- }
415
- function commitInspectionResult(_this__u8e3s4, digResult) {
416
- return new CommitInspectionResult(digResult.m1g_1, digResult.n1g_1, plus(listOf_0([_this__u8e3s4.l1f_1, _this__u8e3s4.k1f_1]), digResult.o1g_1), digResult.p1g_1);
417
- }
418
- function allAuthors(messageDigResults) {
419
- // Inline function 'kotlin.collections.flatMap' call
420
- // Inline function 'kotlin.collections.flatMapTo' call
421
- var destination = ArrayList.n();
422
- var _iterator__ex2g4s = messageDigResults.d1();
423
- while (_iterator__ex2g4s.e1()) {
424
- var element = _iterator__ex2g4s.f1();
425
- // Inline function 'com.zegreatrob.tools.digger.core.allAuthors.stub_for_inlining' call
426
- var list = element.d1g_1;
427
- addAll(destination, list);
428
- }
429
- // Inline function 'kotlin.collections.map' call
430
- // Inline function 'kotlin.collections.mapTo' call
431
- var destination_0 = ArrayList.k1(collectionSizeOrDefault(destination, 10));
432
- var _iterator__ex2g4s_0 = destination.d1();
433
- while (_iterator__ex2g4s_0.e1()) {
434
- var item = _iterator__ex2g4s_0.f1();
435
- // Inline function 'com.zegreatrob.tools.digger.core.allAuthors.<anonymous>' call
436
- // Inline function 'kotlin.text.lowercase' call
437
- // Inline function 'kotlin.js.asDynamic' call
438
- var tmp$ret$5 = item.toLowerCase();
439
- destination_0.o(tmp$ret$5);
440
- }
441
- return toList(sorted(toSet(destination_0)));
442
- }
443
- function mergedStoryIds(messageDigResults) {
444
- // Inline function 'kotlin.collections.mapNotNull' call
445
- // Inline function 'kotlin.collections.mapNotNullTo' call
446
- var destination = ArrayList.n();
447
- // Inline function 'kotlin.collections.forEach' call
448
- var _iterator__ex2g4s = messageDigResults.d1();
449
- while (_iterator__ex2g4s.e1()) {
450
- var element = _iterator__ex2g4s.f1();
451
- // Inline function 'kotlin.collections.mapNotNullTo.<anonymous>' call
452
- // Inline function 'com.zegreatrob.tools.digger.core.mergedStoryIds.stub_for_inlining' call
453
- var tmp0_safe_receiver = element.b1g_1;
454
- if (tmp0_safe_receiver == null)
455
- null;
456
- else {
457
- // Inline function 'kotlin.let' call
458
- // Inline function 'kotlin.collections.mapNotNullTo.<anonymous>.<anonymous>' call
459
- destination.o(tmp0_safe_receiver);
460
- }
461
- }
462
- // Inline function 'kotlin.let' call
463
- // Inline function 'com.zegreatrob.tools.digger.core.mergedStoryIds.<anonymous>' call
464
- var tmp;
465
- // Inline function 'kotlin.collections.isNotEmpty' call
466
- if (!destination.a1()) {
467
- tmp = joinToString(sorted(toSet(destination)), ', ');
468
- } else {
469
- tmp = null;
470
- }
471
- return tmp;
472
- }
473
- function currentContributionCommits(_this__u8e3s4, previousTag) {
474
- var tmp;
475
- if (previousTag == null) {
476
- tmp = _this__u8e3s4.v1f();
477
- } else {
478
- tmp = _this__u8e3s4.w1f('^' + previousTag.y1f_1, 'HEAD');
479
- }
480
- return tmp;
481
- }
482
- function tagRefs($this) {
483
- // Inline function 'kotlin.collections.filter' call
484
- var tmp0 = $this.r1g_1.u1f();
485
- // Inline function 'kotlin.collections.filterTo' call
486
- var destination = ArrayList.n();
487
- var _iterator__ex2g4s = tmp0.d1();
488
- while (_iterator__ex2g4s.e1()) {
489
- var element = _iterator__ex2g4s.f1();
490
- // Inline function 'com.zegreatrob.tools.digger.core.DiggerCore.tagRefs.<anonymous>' call
491
- if ($this.t1g_1.og(element.y1f_1)) {
492
- destination.o(element);
493
- }
494
- }
495
- return destination;
496
- }
497
- function currentRelevantTags($this, headCommitId, lastTwoTags) {
498
- // Inline function 'kotlin.let' call
499
- // Inline function 'com.zegreatrob.tools.digger.core.DiggerCore.currentRelevantTags.<anonymous>' call
500
- var latestTag = getOrNull(lastTwoTags, 0);
501
- var tmp;
502
- if ((latestTag == null ? null : latestTag.z1f_1) === headCommitId) {
503
- tmp = to(latestTag, getOrNull(lastTwoTags, 1));
504
- } else {
505
- tmp = to(null, latestTag);
506
- }
507
- return tmp;
508
- }
509
- var Defaults_instance;
510
- function Defaults_getInstance() {
511
- if (Defaults_instance === VOID)
512
- new Defaults();
513
- return Defaults_instance;
514
- }
515
- var Defaults_instance_0;
516
- function Defaults_getInstance_0() {
517
- if (Defaults_instance_0 === VOID)
518
- new Defaults_0();
519
- return Defaults_instance_0;
520
- }
521
- function cleaned(_this__u8e3s4) {
522
- var first = firstOrNull_0(_this__u8e3s4.fg_1);
523
- var last = lastIndexOf(_this__u8e3s4.fg_1, '/');
524
- var tmp;
525
- var tmp_0 = first;
526
- if (equals(tmp_0 == null ? null : new Char(tmp_0), new Char(_Char___init__impl__6a9atx(47)))) {
527
- // Inline function 'kotlin.text.substring' call
528
- // Inline function 'kotlin.js.asDynamic' call
529
- tmp = _this__u8e3s4.fg_1.substring(1, last);
530
- } else {
531
- tmp = _this__u8e3s4.fg_1;
532
- }
533
- return tmp;
534
- }
535
- function messageDigResult(_this__u8e3s4) {
536
- var tmp3_coauthors = toList_0(mapNotNull(_this__u8e3s4, messageDigResult$lambda));
537
- var tmp4_semver = maxOrNull_0(mapNotNull(_this__u8e3s4, messageDigResult$lambda_0));
538
- var tmp$ret$1;
539
- $l$block: {
540
- // Inline function 'kotlin.sequences.firstNotNullOfOrNull' call
541
- var _iterator__ex2g4s = _this__u8e3s4.d1();
542
- while (_iterator__ex2g4s.e1()) {
543
- var element = _iterator__ex2g4s.f1();
544
- // Inline function 'com.zegreatrob.tools.digger.core.messageDigResult.<anonymous>' call
545
- var result = get(element.zg(), 'storyId');
546
- if (!(result == null)) {
547
- tmp$ret$1 = result;
548
- break $l$block;
549
- }
550
- }
551
- tmp$ret$1 = null;
552
- }
553
- var tmp0_safe_receiver = tmp$ret$1;
554
- var tmp5_storyId = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.vg_1;
555
- var tmp$ret$3;
556
- $l$block_0: {
557
- // Inline function 'kotlin.sequences.firstNotNullOfOrNull' call
558
- var _iterator__ex2g4s_0 = _this__u8e3s4.d1();
559
- while (_iterator__ex2g4s_0.e1()) {
560
- var element_0 = _iterator__ex2g4s_0.f1();
561
- // Inline function 'com.zegreatrob.tools.digger.core.messageDigResult.<anonymous>' call
562
- var result_0 = get(element_0.zg(), 'ease');
563
- if (!(result_0 == null)) {
564
- tmp$ret$3 = result_0;
565
- break $l$block_0;
566
- }
567
- }
568
- tmp$ret$3 = null;
569
- }
570
- var tmp1_safe_receiver = tmp$ret$3;
571
- var tmp2_safe_receiver = tmp1_safe_receiver == null ? null : tmp1_safe_receiver.vg_1;
572
- var tmp6_ease = tmp2_safe_receiver == null ? null : toIntOrNull(tmp2_safe_receiver);
573
- return new MessageDigResult(tmp5_storyId, tmp6_ease, tmp3_coauthors, tmp4_semver);
574
- }
575
- function getSemver(it) {
576
- return groupMatches(it, 'major') ? SemverType_Major_getInstance() : groupMatches(it, 'minor') ? SemverType_Minor_getInstance() : groupMatches(it, 'patch') ? SemverType_Patch_getInstance() : groupMatches(it, 'none') ? SemverType_None_getInstance() : null;
577
- }
578
- function groupMatches(_this__u8e3s4, groupName) {
579
- // Inline function 'kotlin.runCatching' call
580
- var tmp;
581
- try {
582
- // Inline function 'com.zegreatrob.tools.digger.core.groupMatches.<anonymous>' call
583
- // Inline function 'kotlin.Companion.success' call
584
- var value = get(_this__u8e3s4.zg(), groupName);
585
- tmp = _Result___init__impl__xyqfz8(value);
586
- } catch ($p) {
587
- var tmp_0;
588
- if ($p instanceof Error) {
589
- var e = $p;
590
- // Inline function 'kotlin.Companion.failure' call
591
- tmp_0 = _Result___init__impl__xyqfz8(createFailure(e));
592
- } else {
593
- throw $p;
594
- }
595
- tmp = tmp_0;
596
- }
597
- // Inline function 'kotlin.Result.getOrNull' call
598
- var this_0 = tmp;
599
- var tmp_1;
600
- if (_Result___get_isFailure__impl__jpiriv(this_0)) {
601
- tmp_1 = null;
602
- } else {
603
- var tmp_2 = _Result___get_value__impl__bjfvqg(this_0);
604
- tmp_1 = (tmp_2 == null ? true : !(tmp_2 == null)) ? tmp_2 : THROW_CCE();
605
- }
606
- return !(tmp_1 == null);
607
- }
608
- function highestPrioritySemver(_this__u8e3s4) {
609
- return maxOrNull(_this__u8e3s4);
610
- }
611
- function messageDigResult$lambda(it) {
612
- var tmp0_safe_receiver = get(it.zg(), 'coAuthors');
613
- return tmp0_safe_receiver == null ? null : tmp0_safe_receiver.vg_1;
614
- }
615
- function messageDigResult$lambda_0(it) {
616
- return getSemver(it);
617
- }
618
- var SemverType_None_instance;
619
- var SemverType_Patch_instance;
620
- var SemverType_Minor_instance;
621
- var SemverType_Major_instance;
622
- var SemverType_entriesInitialized;
623
- function SemverType_initEntries() {
624
- if (SemverType_entriesInitialized)
625
- return Unit_instance;
626
- SemverType_entriesInitialized = true;
627
- SemverType_None_instance = new SemverType('None', 0);
628
- SemverType_Patch_instance = new SemverType('Patch', 1);
629
- SemverType_Minor_instance = new SemverType('Minor', 2);
630
- SemverType_Major_instance = new SemverType('Major', 3);
631
- }
632
- function SemverType_None_getInstance() {
633
- SemverType_initEntries();
634
- return SemverType_None_instance;
635
- }
636
- function SemverType_Patch_getInstance() {
637
- SemverType_initEntries();
638
- return SemverType_Patch_instance;
639
- }
640
- function SemverType_Minor_getInstance() {
641
- SemverType_initEntries();
642
- return SemverType_Minor_instance;
643
- }
644
- function SemverType_Major_getInstance() {
645
- SemverType_initEntries();
646
- return SemverType_Major_instance;
647
- }
648
- //region block: post-declaration
649
- initMetadataForClass(CommitInspectionResult, 'CommitInspectionResult');
650
- initMetadataForObject(Defaults, 'Defaults');
651
- initMetadataForClass(DiggerCore, 'DiggerCore');
652
- initMetadataForClass(MessageDigResult, 'MessageDigResult');
653
- initMetadataForObject(Defaults_0, 'Defaults');
654
- initMetadataForClass(MessageDigger, 'MessageDigger', MessageDigger);
655
- initMetadataForClass(SemverType, 'SemverType');
656
- //endregion
657
- //region block: exports
658
- export {
659
- DiggerCore as DiggerCore161efnqchht0q,
660
- MessageDigger as MessageDigger36wkxr4fwdcpi,
661
- Defaults_getInstance as Defaults_getInstance34vlepzf7b4c2,
662
- Defaults_getInstance_0 as Defaults_getInstancexfkq3tannrj8,
663
- };
664
- //endregion
665
-
666
- //# sourceMappingURL=tools-digger-core.mjs.map