@commitlint/read 17.0.0 → 17.1.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.
@@ -1,7 +1,5 @@
1
- export declare function getHistoryCommits(options: {
2
- from?: string;
3
- to?: string;
4
- }, opts?: {
1
+ import gitRawCommits from 'git-raw-commits';
2
+ export declare function getHistoryCommits(options: gitRawCommits.GitOptions, opts?: {
5
3
  cwd?: string;
6
4
  }): Promise<string[]>;
7
5
  //# sourceMappingURL=get-history-commits.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"get-history-commits.d.ts","sourceRoot":"","sources":["../src/get-history-commits.ts"],"names":[],"mappings":"AAIA,wBAAsB,iBAAiB,CACtC,OAAO,EAAE;IAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,EAAE,CAAC,EAAE,MAAM,CAAA;CAAC,EACrC,IAAI,GAAE;IAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAM,GACvB,OAAO,CAAC,MAAM,EAAE,CAAC,CAEnB"}
1
+ {"version":3,"file":"get-history-commits.d.ts","sourceRoot":"","sources":["../src/get-history-commits.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,iBAAiB,CAAC;AAI5C,wBAAsB,iBAAiB,CACtC,OAAO,EAAE,aAAa,CAAC,UAAU,EACjC,IAAI,GAAE;IAAC,GAAG,CAAC,EAAE,MAAM,CAAA;CAAM,GACvB,OAAO,CAAC,MAAM,EAAE,CAAC,CAEnB"}
@@ -1 +1 @@
1
- {"version":3,"file":"get-history-commits.js","sourceRoot":"","sources":["../src/get-history-commits.ts"],"names":[],"mappings":";;;;;;AAAA,sEAA4C;AAC5C,2DAAoD;AAEpD,mCAAmC;AAC5B,KAAK,UAAU,iBAAiB,CACtC,OAAqC,EACrC,OAAuB,EAAE;IAEzB,OAAO,IAAA,mCAAe,EAAC,IAAA,yBAAa,EAAC,OAAO,EAAE,EAAC,GAAG,EAAE,IAAI,CAAC,GAAG,EAAC,CAAC,CAAC,CAAC;AACjE,CAAC;AALD,8CAKC"}
1
+ {"version":3,"file":"get-history-commits.js","sourceRoot":"","sources":["../src/get-history-commits.ts"],"names":[],"mappings":";;;;;;AAAA,sEAA4C;AAC5C,2DAAoD;AAEpD,mCAAmC;AAC5B,KAAK,UAAU,iBAAiB,CACtC,OAAiC,EACjC,OAAuB,EAAE;IAEzB,OAAO,IAAA,mCAAe,EAAC,IAAA,yBAAa,EAAC,OAAO,EAAE,EAAC,GAAG,EAAE,IAAI,CAAC,GAAG,EAAC,CAAC,CAAC,CAAC;AACjE,CAAC;AALD,8CAKC"}
package/lib/read.d.ts CHANGED
@@ -3,6 +3,7 @@ interface GetCommitMessageOptions {
3
3
  from?: string;
4
4
  to?: string;
5
5
  edit?: boolean | string;
6
+ gitLogArgs?: string;
6
7
  }
7
8
  export default function getCommitMessages(settings: GetCommitMessageOptions): Promise<string[]>;
8
9
  export {};
package/lib/read.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"read.d.ts","sourceRoot":"","sources":["../src/read.ts"],"names":[],"mappings":"AAGA,UAAU,uBAAuB;IAChC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CACxB;AAGD,wBAA8B,iBAAiB,CAC9C,QAAQ,EAAE,uBAAuB,GAC/B,OAAO,CAAC,MAAM,EAAE,CAAC,CAQnB"}
1
+ {"version":3,"file":"read.d.ts","sourceRoot":"","sources":["../src/read.ts"],"names":[],"mappings":"AAKA,UAAU,uBAAuB;IAChC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;CACpB;AAGD,wBAA8B,iBAAiB,CAC9C,QAAQ,EAAE,uBAAuB,GAC/B,OAAO,CAAC,MAAM,EAAE,CAAC,CAiBnB"}
package/lib/read.js CHANGED
@@ -1,14 +1,23 @@
1
1
  "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
2
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
+ const minimist_1 = __importDefault(require("minimist"));
3
7
  const get_history_commits_1 = require("./get-history-commits");
4
8
  const get_edit_commit_1 = require("./get-edit-commit");
5
9
  // Get commit messages
6
10
  async function getCommitMessages(settings) {
7
- const { cwd, from, to, edit } = settings;
11
+ const { cwd, from, to, edit, gitLogArgs } = settings;
8
12
  if (edit) {
9
13
  return (0, get_edit_commit_1.getEditCommit)(cwd, edit);
10
14
  }
11
- return (0, get_history_commits_1.getHistoryCommits)({ from, to }, { cwd });
15
+ let gitOptions = { from, to };
16
+ if (gitLogArgs) {
17
+ gitOptions = Object.assign(Object.assign({}, (0, minimist_1.default)(gitLogArgs.split(' '))), { from,
18
+ to });
19
+ }
20
+ return (0, get_history_commits_1.getHistoryCommits)(gitOptions, { cwd });
12
21
  }
13
22
  exports.default = getCommitMessages;
14
23
  //# sourceMappingURL=read.js.map
package/lib/read.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"read.js","sourceRoot":"","sources":["../src/read.ts"],"names":[],"mappings":";;AAAA,+DAAwD;AACxD,uDAAgD;AAShD,sBAAsB;AACP,KAAK,UAAU,iBAAiB,CAC9C,QAAiC;IAEjC,MAAM,EAAC,GAAG,EAAE,IAAI,EAAE,EAAE,EAAE,IAAI,EAAC,GAAG,QAAQ,CAAC;IAEvC,IAAI,IAAI,EAAE;QACT,OAAO,IAAA,+BAAa,EAAC,GAAG,EAAE,IAAI,CAAC,CAAC;KAChC;IAED,OAAO,IAAA,uCAAiB,EAAC,EAAC,IAAI,EAAE,EAAE,EAAC,EAAE,EAAC,GAAG,EAAC,CAAC,CAAC;AAC7C,CAAC;AAVD,oCAUC"}
1
+ {"version":3,"file":"read.js","sourceRoot":"","sources":["../src/read.ts"],"names":[],"mappings":";;;;;AAAA,wDAAgC;AAEhC,+DAAwD;AACxD,uDAAgD;AAUhD,sBAAsB;AACP,KAAK,UAAU,iBAAiB,CAC9C,QAAiC;IAEjC,MAAM,EAAC,GAAG,EAAE,IAAI,EAAE,EAAE,EAAE,IAAI,EAAE,UAAU,EAAC,GAAG,QAAQ,CAAC;IAEnD,IAAI,IAAI,EAAE;QACT,OAAO,IAAA,+BAAa,EAAC,GAAG,EAAE,IAAI,CAAC,CAAC;KAChC;IAED,IAAI,UAAU,GAAe,EAAC,IAAI,EAAE,EAAE,EAAC,CAAC;IACxC,IAAI,UAAU,EAAE;QACf,UAAU,mCACN,IAAA,kBAAQ,EAAC,UAAU,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,KAClC,IAAI;YACJ,EAAE,GACF,CAAC;KACF;IAED,OAAO,IAAA,uCAAiB,EAAC,UAAU,EAAE,EAAC,GAAG,EAAC,CAAC,CAAC;AAC7C,CAAC;AAnBD,oCAmBC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@commitlint/read",
3
- "version": "17.0.0",
3
+ "version": "17.1.0",
4
4
  "description": "Read commit messages from a specified range or last edit",
5
5
  "main": "lib/read.js",
6
6
  "types": "lib/read.d.ts",
@@ -39,13 +39,15 @@
39
39
  "@commitlint/utils": "^17.0.0",
40
40
  "@types/fs-extra": "^9.0.1",
41
41
  "@types/git-raw-commits": "^2.0.0",
42
+ "@types/minimist": "^1.2.2",
42
43
  "execa": "^5.0.0"
43
44
  },
44
45
  "dependencies": {
45
46
  "@commitlint/top-level": "^17.0.0",
46
47
  "@commitlint/types": "^17.0.0",
47
48
  "fs-extra": "^10.0.0",
48
- "git-raw-commits": "^2.0.0"
49
+ "git-raw-commits": "^2.0.0",
50
+ "minimist": "^1.2.6"
49
51
  },
50
- "gitHead": "ed437d29464ab1b239deecb84ce4d1f2a5e471c6"
52
+ "gitHead": "a2c25b93e34d37a950609fa4606849a55a1826b4"
51
53
  }
package/CHANGELOG.md DELETED
@@ -1,307 +0,0 @@
1
- # Change Log
2
-
3
- All notable changes to this project will be documented in this file.
4
- See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
-
6
- # [17.0.0](https://github.com/conventional-changelog/commitlint/compare/v16.3.0...v17.0.0) (2022-05-16)
7
-
8
-
9
- * chore!: minimum node version v14 (#3128) ([ac5f9b4](https://github.com/conventional-changelog/commitlint/commit/ac5f9b47a9e3cd5c9d58b14da0feb426f06b1ef9)), closes [#3128](https://github.com/conventional-changelog/commitlint/issues/3128)
10
-
11
-
12
- ### BREAKING CHANGES
13
-
14
- * drop node v12 support
15
-
16
- * chore: rename circleci windows job
17
-
18
- node version is not defned by the name anyways (i think)
19
-
20
-
21
-
22
-
23
-
24
- ## [16.2.1](https://github.com/conventional-changelog/commitlint/compare/v16.2.0...v16.2.1) (2022-02-13)
25
-
26
- **Note:** Version bump only for package @commitlint/read
27
-
28
-
29
-
30
-
31
-
32
- # [16.0.0](https://github.com/conventional-changelog/commitlint/compare/v15.0.0...v16.0.0) (2021-12-26)
33
-
34
- **Note:** Version bump only for package @commitlint/read
35
-
36
-
37
-
38
-
39
-
40
- # [15.0.0](https://github.com/conventional-changelog/commitlint/compare/v14.2.0...v15.0.0) (2021-11-17)
41
-
42
- **Note:** Version bump only for package @commitlint/read
43
-
44
-
45
-
46
-
47
-
48
- # [14.0.0](https://github.com/conventional-changelog/commitlint/compare/v13.2.1...v14.0.0) (2021-10-26)
49
-
50
- **Note:** Version bump only for package @commitlint/read
51
-
52
-
53
-
54
-
55
-
56
- # [13.2.0](https://github.com/conventional-changelog/commitlint/compare/v13.1.0...v13.2.0) (2021-09-28)
57
-
58
- **Note:** Version bump only for package @commitlint/read
59
-
60
-
61
-
62
-
63
-
64
- # [13.1.0](https://github.com/conventional-changelog/commitlint/compare/v13.0.0...v13.1.0) (2021-07-24)
65
-
66
- **Note:** Version bump only for package @commitlint/read
67
-
68
-
69
-
70
-
71
-
72
- # [13.0.0](https://github.com/conventional-changelog/commitlint/compare/v12.1.4...v13.0.0) (2021-05-24)
73
-
74
-
75
- * chore!: remove node 10 support (#2596) ([4db4ba1](https://github.com/conventional-changelog/commitlint/commit/4db4ba1b0b312410a0f62100a93a80c246a6c410)), closes [#2596](https://github.com/conventional-changelog/commitlint/issues/2596)
76
-
77
-
78
- ### BREAKING CHANGES
79
-
80
- * minimum node version is 12
81
-
82
-
83
-
84
-
85
-
86
- ## [12.1.3](https://github.com/conventional-changelog/commitlint/compare/v12.1.2...v12.1.3) (2021-05-12)
87
-
88
-
89
- ### Bug Fixes
90
-
91
- * update dependency fs-extra to v10 ([#2575](https://github.com/conventional-changelog/commitlint/issues/2575)) ([d47d2b5](https://github.com/conventional-changelog/commitlint/commit/d47d2b595b980adadd4fb8ff198c1914caeff18f))
92
-
93
-
94
-
95
-
96
-
97
- ## [12.1.2](https://github.com/conventional-changelog/commitlint/compare/v12.1.1...v12.1.2) (2021-04-29)
98
-
99
- **Note:** Version bump only for package @commitlint/read
100
-
101
-
102
-
103
-
104
-
105
- ## [12.1.1](https://github.com/conventional-changelog/commitlint/compare/v12.1.0...v12.1.1) (2021-04-02)
106
-
107
- **Note:** Version bump only for package @commitlint/read
108
-
109
-
110
-
111
-
112
-
113
- # [12.1.0](https://github.com/conventional-changelog/commitlint/compare/v12.0.1...v12.1.0) (2021-03-06)
114
-
115
- **Note:** Version bump only for package @commitlint/read
116
-
117
-
118
-
119
-
120
-
121
- ## [12.0.1](https://github.com/conventional-changelog/commitlint/compare/v12.0.0...v12.0.1) (2021-02-23)
122
-
123
- **Note:** Version bump only for package @commitlint/read
124
-
125
-
126
-
127
-
128
-
129
- # [12.0.0](https://github.com/conventional-changelog/commitlint/compare/v11.0.0...v12.0.0) (2021-01-18)
130
-
131
- **Note:** Version bump only for package @commitlint/read
132
-
133
-
134
-
135
-
136
-
137
- # [11.0.0](https://github.com/conventional-changelog/commitlint/compare/v10.0.0...v11.0.0) (2020-09-05)
138
-
139
-
140
- ### Bug Fixes
141
-
142
- * update dependency @types/fs-extra to ^9.0.1 ([#2088](https://github.com/conventional-changelog/commitlint/issues/2088)) ([cb1028e](https://github.com/conventional-changelog/commitlint/commit/cb1028ef2700d86991c69a1e2ad391bc1bdc9d90))
143
-
144
-
145
-
146
-
147
-
148
- # [10.0.0](https://github.com/conventional-changelog/commitlint/compare/v9.1.2...v10.0.0) (2020-08-16)
149
-
150
-
151
- ### Bug Fixes
152
-
153
- * update dependency fs-extra to v9 ([#1018](https://github.com/conventional-changelog/commitlint/issues/1018)) ([2df49fa](https://github.com/conventional-changelog/commitlint/commit/2df49fac907993ae78199a1012e918b0e2ff5621))
154
-
155
-
156
- * refactor!: drop support for node 8 (#1999) ([751f39f](https://github.com/conventional-changelog/commitlint/commit/751f39f284ef232574a176c3c11b1982ee544166)), closes [#1999](https://github.com/conventional-changelog/commitlint/issues/1999)
157
-
158
-
159
- ### BREAKING CHANGES
160
-
161
- * remove node 8 from circle-ci checks
162
-
163
- also remove node 13 because we do not support experimental versions
164
-
165
- * docs: update node v10 to latest LTS 10 version
166
-
167
- Co-authored-by: Cedric van Putten <me@bycedric.com>
168
-
169
- Co-authored-by: Cedric van Putten <me@bycedric.com>
170
-
171
-
172
-
173
-
174
-
175
- ## [9.1.2](https://github.com/conventional-changelog/commitlint/compare/v9.1.1...v9.1.2) (2020-07-13)
176
-
177
- **Note:** Version bump only for package @commitlint/read
178
-
179
-
180
-
181
-
182
-
183
- ## [9.1.1](https://github.com/conventional-changelog/commitlint/compare/v9.1.0...v9.1.1) (2020-06-30)
184
-
185
- **Note:** Version bump only for package @commitlint/read
186
-
187
-
188
-
189
-
190
-
191
- # [9.1.0](https://github.com/conventional-changelog/commitlint/compare/v9.0.1...v9.1.0) (2020-06-21)
192
-
193
- **Note:** Version bump only for package @commitlint/read
194
-
195
-
196
-
197
-
198
-
199
- ## [9.0.1](https://github.com/conventional-changelog/commitlint/compare/v9.0.0...v9.0.1) (2020-05-26)
200
-
201
- **Note:** Version bump only for package @commitlint/read
202
-
203
-
204
-
205
-
206
-
207
- # [9.0.0](https://github.com/conventional-changelog/commitlint/compare/v8.3.5...v9.0.0) (2020-05-21)
208
-
209
- **Note:** Version bump only for package @commitlint/read
210
-
211
-
212
-
213
-
214
-
215
- ## [8.3.4](https://github.com/conventional-changelog/commitlint/compare/v8.3.3...v8.3.4) (2020-01-03)
216
-
217
- **Note:** Version bump only for package @commitlint/read
218
-
219
-
220
-
221
-
222
-
223
- # [8.3.0](https://github.com/conventional-changelog/commitlint/compare/v8.2.0...v8.3.0) (2019-10-16)
224
-
225
- **Note:** Version bump only for package @commitlint/read
226
-
227
-
228
-
229
-
230
-
231
- # [8.2.0](https://github.com/conventional-changelog/commitlint/compare/v8.1.0...v8.2.0) (2019-09-16)
232
-
233
- **Note:** Version bump only for package @commitlint/read
234
-
235
-
236
-
237
-
238
-
239
- # [8.1.0](https://github.com/conventional-changelog/commitlint/compare/v8.0.0...v8.1.0) (2019-07-15)
240
-
241
- **Note:** Version bump only for package @commitlint/read
242
-
243
-
244
-
245
-
246
-
247
- # [7.6.0](https://github.com/conventional-changelog/commitlint/compare/v7.5.2...v7.6.0) (2019-05-06)
248
-
249
-
250
- ### Bug Fixes
251
-
252
- * use sander.readFile correctly ([#448](https://github.com/conventional-changelog/commitlint/issues/448)) ([#630](https://github.com/conventional-changelog/commitlint/issues/630)) ([8e47985](https://github.com/conventional-changelog/commitlint/commit/8e47985))
253
-
254
-
255
-
256
-
257
-
258
- <a name="7.5.0"></a>
259
- # [7.5.0](https://github.com/conventional-changelog/commitlint/compare/v7.4.0...v7.5.0) (2019-01-31)
260
-
261
-
262
- ### Bug Fixes
263
-
264
- * all broken website references ([#564](https://github.com/conventional-changelog/commitlint/issues/564)) ([82eeb5a](https://github.com/conventional-changelog/commitlint/commit/82eeb5a))
265
- * replace all repository references with conventional changelog ([#561](https://github.com/conventional-changelog/commitlint/issues/561)) ([6c3afcd](https://github.com/conventional-changelog/commitlint/commit/6c3afcd))
266
- * replace all website references with conventional changelog ([#563](https://github.com/conventional-changelog/commitlint/issues/563)) ([6b86fb1](https://github.com/conventional-changelog/commitlint/commit/6b86fb1))
267
- * resolve path to commit message for git submodules ([83b1a47](https://github.com/conventional-changelog/commitlint/commit/83b1a47))
268
-
269
-
270
- ### Features
271
-
272
- * add support for git submodules ([cc575fa](https://github.com/conventional-changelog/commitlint/commit/cc575fa))
273
-
274
-
275
-
276
-
277
- <a name="7.3.1"></a>
278
- ## [7.3.1](https://github.com/conventional-changelog/commitlint/compare/v7.3.0...v7.3.1) (2019-01-11)
279
-
280
-
281
-
282
-
283
- **Note:** Version bump only for package @commitlint/read
284
-
285
- <a name="7.3.0"></a>
286
- # [7.3.0](https://github.com/conventional-changelog/commitlint/compare/v7.2.1...v7.3.0) (2019-01-11)
287
-
288
-
289
-
290
-
291
- **Note:** Version bump only for package @commitlint/read
292
-
293
- <a name="7.1.2"></a>
294
- ## [7.1.2](https://github.com/conventional-changelog/commitlint/compare/v7.1.1...v7.1.2) (2018-09-04)
295
-
296
-
297
-
298
-
299
- **Note:** Version bump only for package @commitlint/read
300
-
301
- <a name="6.1.1"></a>
302
- ## [6.1.1](https://github.com/conventional-changelog/commitlint/compare/v6.1.0...v6.1.1) (2018-02-22)
303
-
304
-
305
-
306
-
307
- **Note:** Version bump only for package @commitlint/read