@html-validate/commitlint-config 3.3.0 → 3.4.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.
Files changed (2) hide show
  1. package/dist/install.js +74 -38
  2. package/package.json +1 -1
package/dist/install.js CHANGED
@@ -32,14 +32,24 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
32
32
  mod
33
33
  ));
34
34
 
35
- // node_modules/ci-info/vendors.json
35
+ // node_modules/is-ci/node_modules/ci-info/vendors.json
36
36
  var require_vendors = __commonJS({
37
- "node_modules/ci-info/vendors.json"(exports, module) {
37
+ "node_modules/is-ci/node_modules/ci-info/vendors.json"(exports, module) {
38
38
  module.exports = [
39
+ {
40
+ name: "Agola CI",
41
+ constant: "AGOLA",
42
+ env: "AGOLA_GIT_REF",
43
+ pr: "AGOLA_PULL_REQUEST_ID"
44
+ },
39
45
  {
40
46
  name: "Appcircle",
41
47
  constant: "APPCIRCLE",
42
- env: "AC_APPCIRCLE"
48
+ env: "AC_APPCIRCLE",
49
+ pr: {
50
+ env: "AC_GIT_PR",
51
+ ne: "false"
52
+ }
43
53
  },
44
54
  {
45
55
  name: "AppVeyor",
@@ -50,7 +60,15 @@ var require_vendors = __commonJS({
50
60
  {
51
61
  name: "AWS CodeBuild",
52
62
  constant: "CODEBUILD",
53
- env: "CODEBUILD_BUILD_ARN"
63
+ env: "CODEBUILD_BUILD_ARN",
64
+ pr: {
65
+ env: "CODEBUILD_WEBHOOK_EVENT",
66
+ any: [
67
+ "PULL_REQUEST_CREATED",
68
+ "PULL_REQUEST_UPDATED",
69
+ "PULL_REQUEST_REOPENED"
70
+ ]
71
+ }
54
72
  },
55
73
  {
56
74
  name: "Azure Pipelines",
@@ -141,6 +159,11 @@ var require_vendors = __commonJS({
141
159
  constant: "DSARI",
142
160
  env: "DSARI"
143
161
  },
162
+ {
163
+ name: "Earthly",
164
+ constant: "EARTHLY",
165
+ env: "EARTHLY_CI"
166
+ },
144
167
  {
145
168
  name: "Expo Application Services",
146
169
  constant: "EAS",
@@ -151,6 +174,11 @@ var require_vendors = __commonJS({
151
174
  constant: "GERRIT",
152
175
  env: "GERRIT_PROJECT"
153
176
  },
177
+ {
178
+ name: "Gitea Actions",
179
+ constant: "GITEA_ACTIONS",
180
+ env: "GITEA_ACTIONS"
181
+ },
154
182
  {
155
183
  name: "GitHub Actions",
156
184
  constant: "GITHUB_ACTIONS",
@@ -236,6 +264,11 @@ var require_vendors = __commonJS({
236
264
  ne: "false"
237
265
  }
238
266
  },
267
+ {
268
+ name: "Prow",
269
+ constant: "PROW",
270
+ env: "PROW_JOB_ID"
271
+ },
239
272
  {
240
273
  name: "ReleaseHub",
241
274
  constant: "RELEASEHUB",
@@ -270,20 +303,6 @@ var require_vendors = __commonJS({
270
303
  env: "SEMAPHORE",
271
304
  pr: "PULL_REQUEST_NUMBER"
272
305
  },
273
- {
274
- name: "Shippable",
275
- constant: "SHIPPABLE",
276
- env: "SHIPPABLE",
277
- pr: {
278
- IS_PULL_REQUEST: "true"
279
- }
280
- },
281
- {
282
- name: "Solano CI",
283
- constant: "SOLANO",
284
- env: "TDDIUM",
285
- pr: "TDDIUM_PR_ID"
286
- },
287
306
  {
288
307
  name: "Sourcehut",
289
308
  constant: "SOURCEHUT",
@@ -318,6 +337,14 @@ var require_vendors = __commonJS({
318
337
  ne: "false"
319
338
  }
320
339
  },
340
+ {
341
+ name: "Vela",
342
+ constant: "VELA",
343
+ env: "VELA",
344
+ pr: {
345
+ VELA_PULL_REQUEST: "1"
346
+ }
347
+ },
321
348
  {
322
349
  name: "Vercel",
323
350
  constant: "VERCEL",
@@ -359,9 +386,9 @@ var require_vendors = __commonJS({
359
386
  }
360
387
  });
361
388
 
362
- // node_modules/ci-info/index.js
389
+ // node_modules/is-ci/node_modules/ci-info/index.js
363
390
  var require_ci_info = __commonJS({
364
- "node_modules/ci-info/index.js"(exports) {
391
+ "node_modules/is-ci/node_modules/ci-info/index.js"(exports) {
365
392
  "use strict";
366
393
  var vendors = require_vendors();
367
394
  var env = process.env;
@@ -372,6 +399,7 @@ var require_ci_info = __commonJS({
372
399
  });
373
400
  exports.name = null;
374
401
  exports.isPR = null;
402
+ exports.id = null;
375
403
  vendors.forEach(function(vendor) {
376
404
  const envs = Array.isArray(vendor.env) ? vendor.env : [vendor.env];
377
405
  const isCI2 = envs.every(function(obj) {
@@ -382,24 +410,8 @@ var require_ci_info = __commonJS({
382
410
  return;
383
411
  }
384
412
  exports.name = vendor.name;
385
- switch (typeof vendor.pr) {
386
- case "string":
387
- exports.isPR = !!env[vendor.pr];
388
- break;
389
- case "object":
390
- if ("env" in vendor.pr) {
391
- exports.isPR = vendor.pr.env in env && env[vendor.pr.env] !== vendor.pr.ne;
392
- } else if ("any" in vendor.pr) {
393
- exports.isPR = vendor.pr.any.some(function(key) {
394
- return !!env[key];
395
- });
396
- } else {
397
- exports.isPR = checkEnv(vendor.pr);
398
- }
399
- break;
400
- default:
401
- exports.isPR = null;
402
- }
413
+ exports.isPR = checkPR(vendor);
414
+ exports.id = vendor.constant;
403
415
  });
404
416
  exports.isCI = !!(env.CI !== "false" && // Bypass all checks if CI env is explicitly set to 'false'
405
417
  (env.BUILD_ID || // Jenkins, Cloudbees
@@ -426,6 +438,30 @@ var require_ci_info = __commonJS({
426
438
  return env[k] === obj[k];
427
439
  });
428
440
  }
441
+ function checkPR(vendor) {
442
+ switch (typeof vendor.pr) {
443
+ case "string":
444
+ return !!env[vendor.pr];
445
+ case "object":
446
+ if ("env" in vendor.pr) {
447
+ if ("any" in vendor.pr) {
448
+ return vendor.pr.any.some(function(key) {
449
+ return env[vendor.pr.env] === key;
450
+ });
451
+ } else {
452
+ return vendor.pr.env in env && env[vendor.pr.env] !== vendor.pr.ne;
453
+ }
454
+ } else if ("any" in vendor.pr) {
455
+ return vendor.pr.any.some(function(key) {
456
+ return !!env[key];
457
+ });
458
+ } else {
459
+ return checkEnv(vendor.pr);
460
+ }
461
+ default:
462
+ return null;
463
+ }
464
+ }
429
465
  }
430
466
  });
431
467
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@html-validate/commitlint-config",
3
- "version": "3.3.0",
3
+ "version": "3.4.0",
4
4
  "description": "Commitlint sharable config used by the various HTML-validate packages",
5
5
  "keywords": [
6
6
  "commitlint"