@code-pushup/core 0.9.0 → 0.10.1
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/index.js +14 -2
- package/package.json +2 -2
package/index.js
CHANGED
|
@@ -582,6 +582,18 @@ function formatDuration(duration) {
|
|
|
582
582
|
}
|
|
583
583
|
return `${(duration / 1e3).toFixed(2)} s`;
|
|
584
584
|
}
|
|
585
|
+
function formatDate(date) {
|
|
586
|
+
const locale = "en-US";
|
|
587
|
+
return date.toLocaleString(locale, {
|
|
588
|
+
weekday: "short",
|
|
589
|
+
month: "short",
|
|
590
|
+
day: "numeric",
|
|
591
|
+
year: "numeric",
|
|
592
|
+
hour: "numeric",
|
|
593
|
+
minute: "2-digit",
|
|
594
|
+
timeZoneName: "short"
|
|
595
|
+
}).replace(/\u202F/g, " ");
|
|
596
|
+
}
|
|
585
597
|
|
|
586
598
|
// packages/utils/src/lib/guards.ts
|
|
587
599
|
function isPromiseFulfilledResult(result) {
|
|
@@ -1215,7 +1227,7 @@ function reportToDetailsSection(audit) {
|
|
|
1215
1227
|
return details(detailsTitle, detailsTable);
|
|
1216
1228
|
}
|
|
1217
1229
|
function reportToAboutSection(report, commitData) {
|
|
1218
|
-
const date = (/* @__PURE__ */ new Date())
|
|
1230
|
+
const date = formatDate(/* @__PURE__ */ new Date());
|
|
1219
1231
|
const { duration, version: version2, plugins, categories } = report;
|
|
1220
1232
|
const commitInfo = commitData ? `${commitData.message} (${commitData.hash.slice(0, 7)})` : "N/A";
|
|
1221
1233
|
const reportMetaTable = [
|
|
@@ -1668,7 +1680,7 @@ function auditOutputsCorrelateWithPluginOutput(auditOutputs, pluginConfigAudits)
|
|
|
1668
1680
|
|
|
1669
1681
|
// packages/core/package.json
|
|
1670
1682
|
var name = "@code-pushup/core";
|
|
1671
|
-
var version = "0.
|
|
1683
|
+
var version = "0.10.1";
|
|
1672
1684
|
|
|
1673
1685
|
// packages/core/src/lib/implementation/collect.ts
|
|
1674
1686
|
async function collect(options) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@code-pushup/core",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.1",
|
|
4
|
+
"license": "MIT",
|
|
4
5
|
"dependencies": {
|
|
5
6
|
"@code-pushup/models": "*",
|
|
6
7
|
"@code-pushup/utils": "*",
|
|
@@ -9,7 +10,6 @@
|
|
|
9
10
|
},
|
|
10
11
|
"type": "module",
|
|
11
12
|
"main": "./index.js",
|
|
12
|
-
"license": "MIT",
|
|
13
13
|
"homepage": "https://github.com/code-pushup/cli#readme",
|
|
14
14
|
"bugs": {
|
|
15
15
|
"url": "https://github.com/code-pushup/cli/issues"
|