@pd4castr/cli 1.4.1 → 1.6.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/dist/index.js +10 -6
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -103,7 +103,8 @@ var projectConfigSchema = z.object({
|
|
|
103
103
|
timeHorizon: z.enum([
|
|
104
104
|
"day_ahead",
|
|
105
105
|
"week_ahead",
|
|
106
|
-
"quarterly"
|
|
106
|
+
"quarterly",
|
|
107
|
+
"historical"
|
|
107
108
|
]),
|
|
108
109
|
displayTimezone: z.string().refine(isIanaTimeZone, "invalid IANA time zone").optional().default("Australia/Brisbane"),
|
|
109
110
|
metadata: z.record(z.string(), z.any()).optional(),
|
|
@@ -792,8 +793,10 @@ __name(pushDockerImage, "pushDockerImage");
|
|
|
792
793
|
// src/utils/get-docker-image.ts
|
|
793
794
|
import slugify from "slugify";
|
|
794
795
|
function getDockerImage(ctx) {
|
|
795
|
-
const
|
|
796
|
-
|
|
796
|
+
const cleanedName = ctx.config.name.replaceAll(/[@#$%^&*()]/g, "");
|
|
797
|
+
const sluggedName = slugify(cleanedName, {
|
|
798
|
+
lower: true,
|
|
799
|
+
strict: true
|
|
797
800
|
});
|
|
798
801
|
const dockerImage = `pd4castr/${sluggedName}-local:${Date.now()}`;
|
|
799
802
|
return dockerImage;
|
|
@@ -1508,7 +1511,7 @@ async function handleAction5(options) {
|
|
|
1508
1511
|
spinner.fail(error.message);
|
|
1509
1512
|
}
|
|
1510
1513
|
if (error instanceof Error && error.cause instanceof ExecaError5) {
|
|
1511
|
-
console.error(error.cause.
|
|
1514
|
+
console.error(error.cause.stderr);
|
|
1512
1515
|
} else if (error instanceof Error && error.cause) {
|
|
1513
1516
|
console.error(error.cause);
|
|
1514
1517
|
}
|
|
@@ -1662,7 +1665,7 @@ ${clickHereLink} to view output (${fileLink})
|
|
|
1662
1665
|
spinner.fail(error.message);
|
|
1663
1666
|
}
|
|
1664
1667
|
if (error instanceof Error && error.cause instanceof ExecaError6) {
|
|
1665
|
-
console.error(error.cause.
|
|
1668
|
+
console.error(error.cause.stderr);
|
|
1666
1669
|
} else if (error instanceof Error && error.cause) {
|
|
1667
1670
|
console.error(error.cause);
|
|
1668
1671
|
}
|
|
@@ -1689,10 +1692,11 @@ import { Command } from "commander";
|
|
|
1689
1692
|
// package.json
|
|
1690
1693
|
var package_default = {
|
|
1691
1694
|
name: "@pd4castr/cli",
|
|
1692
|
-
version: "1.
|
|
1695
|
+
version: "1.6.0",
|
|
1693
1696
|
description: "CLI tool for creating, testing, and publishing pd4castr models",
|
|
1694
1697
|
license: "UNLICENSED",
|
|
1695
1698
|
main: "dist/index.js",
|
|
1699
|
+
private: false,
|
|
1696
1700
|
type: "module",
|
|
1697
1701
|
bin: {
|
|
1698
1702
|
pd4castr: "dist/index.js"
|
package/package.json
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pd4castr/cli",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "CLI tool for creating, testing, and publishing pd4castr models",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
|
+
"private": false,
|
|
7
8
|
"type": "module",
|
|
8
9
|
"bin": {
|
|
9
10
|
"pd4castr": "dist/index.js"
|