@keystrokehq/cli 0.0.20 → 0.0.22
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/{accept.handler-CiqqUxKN.mjs → accept.handler-C6KBLKmW.mjs} +1 -1
- package/dist/{admin-B0U2Aghv.mjs → admin-D2CQoZAN.mjs} +9 -9
- package/dist/{agent-bundle-package-DWV6B_5q-BsbCEeMw.mjs → agent-bundle-package-DWV6B_5q-B-qzc3zC.mjs} +1 -1
- package/dist/{agents-DBebUEwk.mjs → agents-Bn0g5o0o.mjs} +7 -7
- package/dist/{api-BjBpWWlm.mjs → api-O5tdGdzc.mjs} +30 -4
- package/dist/{api-keys-BHAgmC4E.mjs → api-keys-BixCnZJW.mjs} +5 -5
- package/dist/{auth-D-PZAjdd.mjs → auth-yCNMT8sJ.mjs} +14 -7
- package/dist/{auth.handler-CxTDSO6O.mjs → auth.handler-BedGpKh1.mjs} +7 -12
- package/dist/{build-agents-DseUtzd4-BNtZrqoY.mjs → build-agents-DseUtzd4-DFh2e5Cn.mjs} +5 -5
- package/dist/{build-metadata-BB_L45ZS-d5-QLDZ5.mjs → build-metadata-BB_L45ZS-BtGGjHIV.mjs} +7 -7
- package/dist/{build-progress-BVwDg6lC.mjs → build-progress-nYa14iBP.mjs} +1 -1
- package/dist/{build-tasks-C09SdfjC-DxKcmENc.mjs → build-tasks-C09SdfjC-B0F7BZZG.mjs} +3 -3
- package/dist/{build-workflows-BZ_m97Pr-DwcnRlyh.mjs → build-workflows-BZ_m97Pr-DKANy85L.mjs} +9 -8
- package/dist/{build.handler-CTX80S1K.mjs → build.handler-CyDc8jiZ.mjs} +5 -5
- package/dist/{chunk-DYxdGL9S.mjs → chunk-CH6r78ws.mjs} +1 -2
- package/dist/{clear-cache.handler-8RFmjHoo.mjs → clear-cache.handler-FmJPHdWG.mjs} +1 -1
- package/dist/{clear.handler-Bksm2HI4.mjs → clear.handler-Cvb9chs4.mjs} +27 -13
- package/dist/{commander-DQLrBSIW.mjs → commander-9Kro0Dl3.mjs} +4 -7
- package/dist/common-AK0q0Oz0.mjs +20 -0
- package/dist/{connect-DV_EztVs.mjs → connect-_l7Lkfxi.mjs} +26 -2
- package/dist/{connect.handler-DbuGt3Xb.mjs → connect.handler-tqk-DOv8.mjs} +39 -4
- package/dist/{context-BUzxM3QI.mjs → context-B2cQ-Nt3.mjs} +30 -4
- package/dist/{create.handler-CQCRk-Na.mjs → create.handler-v9B0Z9Yf.mjs} +1 -1
- package/dist/{credential-env-map-qLCR_QbO.mjs → credential-env-map-Dvp00a4M.mjs} +1 -1
- package/dist/credential-requirements-D0mavK8j-CFMf0Xwu.mjs +619 -0
- package/dist/{credentials-xPtLFTjW.mjs → credentials-DQW8xxof.mjs} +2 -2
- package/dist/{credentials-m18a1_hw.mjs → credentials-Dr5lD7Hm.mjs} +6 -6
- package/dist/{current-deployment-workflow-pyBoobIm.mjs → current-deployment-workflow-qMfOrRIu.mjs} +4 -4
- package/dist/{current.handler-BJGJgdGP.mjs → current.handler-Cm_-JLyZ.mjs} +1 -1
- package/dist/declared-credential-requirements-B6h4WRv4.mjs +103 -0
- package/dist/{delete.handler-DNoehdOH.mjs → delete.handler-DtP_zUaq.mjs} +1 -1
- package/dist/{deploy-BKjcO_sm.mjs → deploy-BURTx92e.mjs} +1 -1
- package/dist/{deploy-3tHCBGky.mjs → deploy-CB6pfCuB.mjs} +2 -2
- package/dist/{deploy-progress-CyolzjRB.mjs → deploy-progress-Dlp9aBDW.mjs} +1 -1
- package/dist/{deploy.handler-TnPNBYXZ.mjs → deploy.handler-Bg0dpSTj.mjs} +16 -16
- package/dist/{detect-env-access-CwkOYeYM-D8-hxij0.mjs → detect-env-access-CwkOYeYM-D4aTZv4R.mjs} +2 -2
- package/dist/{diff.handler-DO2WzdGB.mjs → diff.handler-CJPrszL1.mjs} +4 -4
- package/dist/{dist-BGrWr5fp.mjs → dist-Br4m3sFZ.mjs} +14 -12
- package/dist/{dist-CIInPRGh.mjs → dist-DuJjDZIf.mjs} +25 -2
- package/dist/{env.handler-C5GNyiJt.mjs → env.handler-6TrLd3fo.mjs} +7 -7
- package/dist/{error-boundary-GtRvP2oP.mjs → error-boundary-DVZipk-A.mjs} +1 -1
- package/dist/{file-metadata-B8c7Y5yg.mjs → file-metadata-DQVDjr7M.mjs} +1 -1
- package/dist/{import-module-y0glInUe-CfNsQNia.mjs → import-module-y0glInUe-DxX0-BRO.mjs} +274 -28
- package/dist/{init-D9RIT2CY.mjs → init-DBMtY3eO.mjs} +3 -3
- package/dist/{init.handler-0TJY1YNy.mjs → init.handler-BoYbE-6H.mjs} +3 -3
- package/dist/{inspect.handler-BrYFfN4H.mjs → inspect.handler-Juu2vGbB.mjs} +4 -4
- package/dist/{integration-catalog-BrJsBkfx.mjs → integration-catalog-cYlTmOSb.mjs} +1 -1
- package/dist/{integrations-vSyAQ6HA.mjs → integrations-Cdq7iSLj.mjs} +5 -5
- package/dist/{invites-BASM4PJr.mjs → invites-DHyHZOY_.mjs} +4 -4
- package/dist/{invites.list.handler-c-aw6g5o.mjs → invites.list.handler-C-QpsG2J.mjs} +1 -1
- package/dist/{invites.resend.handler-MnMEjP_Z.mjs → invites.resend.handler-KFKbSPzR.mjs} +1 -1
- package/dist/{invites.revoke.handler-CHX6Z8kj.mjs → invites.revoke.handler-Cuz7jrGC.mjs} +1 -1
- package/dist/keystroke.mjs +21 -21
- package/dist/{list-enrichment-DcplcioC.mjs → list-enrichment-CCRHYslm.mjs} +1 -1
- package/dist/{list.handler-DJNtXw7C.mjs → list.handler-6x3GVumu.mjs} +1 -1
- package/dist/{list2.handler-BdE1k2kl.mjs → list.handler-BWsl4iYw.mjs} +4 -4
- package/dist/{list.handler-BsgCd1oF.mjs → list.handler-CLGQDuo5.mjs} +5 -5
- package/dist/{list.handler-CynN-ezD.mjs → list.handler-Cc-V1TNz.mjs} +1 -1
- package/dist/{list.handler-DXwKdfIv.mjs → list.handler-DRe38pAj.mjs} +2 -2
- package/dist/{list.handler-CDtjm-6d.mjs → list.handler-Do2tVOnu.mjs} +1 -1
- package/dist/{list.handler-BBzB1_1l.mjs → list.handler-RtHhrTZ3.mjs} +1 -1
- package/dist/{listen-Ca9KdiB2.mjs → listen-DZdSevsB.mjs} +2 -2
- package/dist/{listen.handler-KWPN03S8.mjs → listen.handler-BccHe1jh.mjs} +2 -2
- package/dist/{logs-BEDf7hZ0.mjs → logs-Bh_PBnu6.mjs} +3 -3
- package/dist/{logs.handler-mk1lcZbU.mjs → logs.handler-DItDS1zw.mjs} +2 -2
- package/dist/{members.add.handler-CTvlxBZU.mjs → members.add.handler-D3nQ_Ln6.mjs} +1 -1
- package/dist/{members.invite.handler-wFO0r7Pi.mjs → members.invite.handler-rKhg5n_C.mjs} +1 -1
- package/dist/{members.list.handler-PPdqs4nI.mjs → members.list.handler-C9Yh469k.mjs} +1 -1
- package/dist/{members.remove.handler-a5WI6zE4.mjs → members.remove.handler-Dnrck-E6.mjs} +1 -1
- package/dist/{members.update.handler-3xblTzmz.mjs → members.update.handler-qo5r6arJ.mjs} +1 -1
- package/dist/{metadata-layout-Bv-B0nHj-DtMWZ7Cc.mjs → metadata-layout-Bv-B0nHj-CO8mjjSl.mjs} +1 -1
- package/dist/{normalize-path-CojS-CgQ-CRqBc6D6.mjs → normalize-path-CojS-CgQ-aOM0agxS.mjs} +1 -1
- package/dist/{org-CzLw3neZ.mjs → org-DnES84sS.mjs} +15 -15
- package/dist/{orgs.create.handler-CcPpDweZ.mjs → orgs.create.handler-DF4eEL-2.mjs} +1 -1
- package/dist/{orgs.get.handler-BACPg7vR.mjs → orgs.get.handler-BmJnseQa.mjs} +1 -1
- package/dist/{orgs.list.handler-DEF8OyvM.mjs → orgs.list.handler-DDVvSbsT.mjs} +1 -1
- package/dist/{paused.handler-D4j8_Za4.mjs → paused.handler-BLUchSMD.mjs} +1 -1
- package/dist/{projects-CJCKxG2u.mjs → projects-Cv14bBGy.mjs} +4 -4
- package/dist/{projects-s5ehKLil.mjs → projects-ZNcKwds2.mjs} +2 -2
- package/dist/{requirements.handler-Bk-sAE9C.mjs → requirements.handler-BKFocUof.mjs} +5 -5
- package/dist/{resolve-cli-credentials-DytxgMwn.mjs → resolve-cli-credentials-DaMDaamj.mjs} +1 -1
- package/dist/{resolve-project-CWP2fji3.mjs → resolve-project-Cj3MFnU0.mjs} +1 -1
- package/dist/{run-polling-DKclfet-.mjs → run-polling-3XOGl4hh.mjs} +3 -3
- package/dist/{run.handler-x0B-CjNF.mjs → run.handler-DZuUx0fi.mjs} +5 -5
- package/dist/{runs-DoMVOCNj.mjs → runs-BOo3j297.mjs} +2 -2
- package/dist/schemas-D2zfmyC-.mjs +671 -0
- package/dist/{skills-sync.handler-CYkCeuQn.mjs → skills-sync.handler-09mDbx5q.mjs} +1 -1
- package/dist/{skills.command-DeAgMGGw.mjs → skills.command-B-MhRN3J.mjs} +4 -4
- package/dist/{source-analysis-BBg2E_6G-BJTRqWrQ.mjs → source-analysis-BBg2E_6G-wPP9mjQx.mjs} +3 -3
- package/dist/{source-analysis-BMMPIHN9.mjs → source-analysis-z2RSZw6X.mjs} +1 -1
- package/dist/{src-BYQwp8Ig.mjs → src-DNhUmpSl.mjs} +1 -1
- package/dist/{switch.handler-CV4ZBXAu.mjs → switch.handler-BFGvj5c6.mjs} +2 -2
- package/dist/{sync-KCVM02IY.mjs → sync-CZ3iUPTA.mjs} +2 -2
- package/dist/{sync.handler-Cuw89341.mjs → sync.handler-B1L8I9lF.mjs} +7 -7
- package/dist/{task-BSCN9cU4.mjs → task-BWuIKWh4.mjs} +2 -392
- package/dist/{task-target-build-B0HF2_At.mjs → task-target-build-CTgl4L42.mjs} +5 -5
- package/dist/{task-target-deploy-ClbwKJ8K.mjs → task-target-deploy-DeUyfi9H.mjs} +1 -1
- package/dist/{task-target-deploy-dQYnMO8n-CeTmRcDw.mjs → task-target-deploy-dQYnMO8n-d2vdeqXH.mjs} +1 -1
- package/dist/task-target-deploy-runner.mjs +6 -6
- package/dist/{test-Rm3thni3.mjs → test-Byq4hG3C.mjs} +2 -2
- package/dist/{test.handler-CTd-heRS.mjs → test.handler-BsrMMj5O.mjs} +9 -9
- package/dist/{test.handler-DhhcsvHN.mjs → test.handler-CAsVgOpT.mjs} +1 -1
- package/dist/{tool.handler-C3LNyQbc.mjs → tool.handler-BHS5Z4J_.mjs} +63 -9
- package/dist/{trigger-artifacts-BcRScRSp-DqFgzl_B.mjs → trigger-artifacts-BcRScRSp-C-JBJ6y8.mjs} +4 -4
- package/dist/{trigger-manifest-DTni4NaZ.mjs → trigger-manifest-C07EM-b2.mjs} +6 -5
- package/dist/{upgrade-Cf7y38xR.mjs → upgrade-bZVjVXnu.mjs} +2 -2
- package/dist/{upload-CJWApEgz.mjs → upload-CE4H5R1h.mjs} +1 -1
- package/dist/{upload.handler-BHIWYPph.mjs → upload.handler-DXVx2u3A.mjs} +7 -7
- package/dist/{users.get.handler-spWaHG8h.mjs → users.get.handler-DqD2ELK2.mjs} +1 -1
- package/dist/{users.list.handler-DLuU7cd_.mjs → users.list.handler-DZSPvpGF.mjs} +1 -1
- package/dist/{users.set-role.handler-CojFmpcD.mjs → users.set-role.handler-73smNUVF.mjs} +1 -1
- package/dist/{utils-Ddltm1sR.mjs → utils-BaxDlCsW.mjs} +1 -1
- package/dist/{validate.handler-DIJBuX1P.mjs → validate.handler-CmfcMX0t.mjs} +4 -4
- package/dist/{workflow-build-IGYhEC8Y.mjs → workflow-build-Bi1Aacc5.mjs} +20 -20
- package/dist/workflow-build-manifest-1sC52TIG.mjs +259 -0
- package/dist/{workflow-bundler-BzHk73PM-Cs-4Ml-p.mjs → workflow-bundler-BzHk73PM-xQwAF08W.mjs} +2 -2
- package/dist/{workflows-MANdvLft.mjs → workflows-C_C13Zr0.mjs} +16 -14
- package/dist/{writer-byNNUjRm-w5O7-VT_.mjs → writer-byNNUjRm-B-on1n6c.mjs} +6 -6
- package/package.json +6 -6
- package/dist/schemas-U2OzP9gP.mjs +0 -281
- package/dist/src-BHTjsZ9V.mjs +0 -456
- /package/dist/{agent-manifest-CZ7BeUSG.mjs → agent-manifest-Pg0aURo7.mjs} +0 -0
- /package/dist/{browser-Cu4k-wT_.mjs → browser-Dvv5OQrt.mjs} +0 -0
- /package/dist/{clear.handler-mfNmIUYP.mjs → clear.handler-BdR56Cok.mjs} +0 -0
- /package/dist/{concurrency-gXn9Rw8x-BSBbRfVp.mjs → concurrency-gXn9Rw8x-CnBnF2cg.mjs} +0 -0
- /package/dist/{credential-schema-mismatch-BHI_B-U-.mjs → credential-schema-mismatch-kfGeiSB1.mjs} +0 -0
- /package/dist/{diff-utils-x5pi8SrL.mjs → diff-utils-CXKNQUXO.mjs} +0 -0
- /package/dist/{layout-DRf9qUf8.mjs → layout-B95Tku8F.mjs} +0 -0
- /package/dist/{logs.handler-CcA1UzJm.mjs → logs.handler-Bs1DVMaO.mjs} +0 -0
- /package/dist/{oxc-B3KI3rf_-Cnk0L10M.mjs → oxc-B3KI3rf_-B9omBIuN.mjs} +0 -0
- /package/dist/{read-credential-keys-77a91T8M-CzXPGxdU.mjs → read-credential-keys-77a91T8M-aLuQvlIq.mjs} +0 -0
- /package/dist/{register.handler-CSvlOMF6.mjs → register.handler-C_NqMLir.mjs} +0 -0
- /package/dist/{rolldown-runtime-twds-ZHy-BoF7MLzP.mjs → rolldown-runtime-twds-ZHy-RuJszab7.mjs} +0 -0
- /package/dist/{run-polling-CzyVv7Ba.mjs → run-polling-DKWPGLyF.mjs} +0 -0
- /package/dist/{schema-CvSZqa3t.mjs → schema-DFJiNWyd.mjs} +0 -0
- /package/dist/{schema-display-DxLA3j5H.mjs → schema-display-XrRCdFL0.mjs} +0 -0
- /package/dist/{skill-installer-CYFshTBy.mjs → skill-installer-Cm9hF6OB.mjs} +0 -0
- /package/dist/{skills.handler-Bma-MJX-.mjs → skills.handler-KEUkV5NH.mjs} +0 -0
- /package/dist/{spinner-progress-DV28G4tP.mjs → spinner-progress-BtEIJRX4.mjs} +0 -0
- /package/dist/{status.handler-BOV0eX3J.mjs → status.handler-CW-EFhy3.mjs} +0 -0
- /package/dist/{types-DamInJD6.mjs → types-D1cVpE7_.mjs} +0 -0
- /package/dist/{upgrade.handler-Bz_oQcAw.mjs → upgrade.handler-C7KvNL0x.mjs} +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { n as JsonOptionSchema, t as JSON_OPTION_CONFIG } from "./output-BWcVRt-T.mjs";
|
|
4
|
-
import { t as createTypedCommand } from "./commander-
|
|
5
|
-
import { t as SKILL_INSTALL_METHODS } from "./types-
|
|
4
|
+
import { t as createTypedCommand } from "./commander-9Kro0Dl3.mjs";
|
|
5
|
+
import { t as SKILL_INSTALL_METHODS } from "./types-D1cVpE7_.mjs";
|
|
6
6
|
import { z } from "zod";
|
|
7
7
|
//#region src/commands/skills/skills.command.ts
|
|
8
8
|
const SkillsCommandOptionsSchema = JsonOptionSchema.extend({
|
|
@@ -32,13 +32,13 @@ function createSkillsCommand() {
|
|
|
32
32
|
description: "Sync Keystroke agent skills (SKILL.md) from @keystrokehq/skills",
|
|
33
33
|
schema: SkillsCommandOptionsSchema,
|
|
34
34
|
optionsConfig: SKILLS_OPTIONS_CONFIG,
|
|
35
|
-
loadHandler: async () => (await import("./skills.handler-
|
|
35
|
+
loadHandler: async () => (await import("./skills.handler-KEUkV5NH.mjs")).handleSkillsParent,
|
|
36
36
|
subcommands: [createTypedCommand({
|
|
37
37
|
name: "sync",
|
|
38
38
|
description: "Install bundled Keystroke skills into selected agent skill directories",
|
|
39
39
|
schema: SkillsCommandOptionsSchema,
|
|
40
40
|
optionsConfig: SKILLS_OPTIONS_CONFIG,
|
|
41
|
-
loadHandler: async () => (await import("./skills-sync.handler-
|
|
41
|
+
loadHandler: async () => (await import("./skills-sync.handler-09mDbx5q.mjs")).handleSkillsSync
|
|
42
42
|
})]
|
|
43
43
|
});
|
|
44
44
|
cmd.enablePositionalOptions();
|
package/dist/{source-analysis-BBg2E_6G-BJTRqWrQ.mjs → source-analysis-BBg2E_6G-wPP9mjQx.mjs}
RENAMED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import { d as getMetadataRoot } from "./layout-
|
|
4
|
-
import { t as BASE_IGNORE_PATTERNS } from "./metadata-layout-Bv-B0nHj-
|
|
5
|
-
import { a as literalString, l as unwrapExpression, n as identifierName, r as isNode } from "./oxc-B3KI3rf_-
|
|
3
|
+
import { d as getMetadataRoot } from "./layout-B95Tku8F.mjs";
|
|
4
|
+
import { t as BASE_IGNORE_PATTERNS } from "./metadata-layout-Bv-B0nHj-CO8mjjSl.mjs";
|
|
5
|
+
import { a as literalString, l as unwrapExpression, n as identifierName, r as isNode } from "./oxc-B3KI3rf_-B9omBIuN.mjs";
|
|
6
6
|
import path from "node:path";
|
|
7
7
|
import { readFile, readdir, rm } from "node:fs/promises";
|
|
8
8
|
//#region ../../packages/workflow-builder/dist/source-analysis-BBg2E_6G.mjs
|
|
@@ -72,4 +72,4 @@ const CapturedVariableSchema = z.object({
|
|
|
72
72
|
})
|
|
73
73
|
});
|
|
74
74
|
//#endregion
|
|
75
|
-
export {
|
|
75
|
+
export { SourceLocationSchema as a, ImportSourceSchema as i, CallsiteFingerprintSchema as n, CapturedVariableSchema as r, CallKindSchema as t };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import { a as createKyInstance, i as buildSearchParams, n as auth, r as bundles, s as getClientEnv, t as projects$1 } from "./projects-
|
|
3
|
+
import { a as createKyInstance, i as buildSearchParams, n as auth, r as bundles, s as getClientEnv, t as projects$1 } from "./projects-ZNcKwds2.mjs";
|
|
4
4
|
//#region ../../packages/workflow-sdk/src/v1/admin.ts
|
|
5
5
|
const admin = (api) => ({
|
|
6
6
|
orgs: {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { a as ui, j as throwReportedCliExit } from "./keystroke.mjs";
|
|
4
|
-
import { n as credentials } from "./dist-
|
|
5
|
-
import { i as requireClient } from "./context-
|
|
4
|
+
import { n as credentials } from "./dist-DuJjDZIf.mjs";
|
|
5
|
+
import { i as requireClient } from "./context-B2cQ-Nt3.mjs";
|
|
6
6
|
import { select } from "@clack/prompts";
|
|
7
7
|
//#region src/commands/org/switch.handler.ts
|
|
8
8
|
async function handleOrgSwitch(_options, ctx) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import { t as createTypedCommand } from "./commander-
|
|
3
|
+
import { t as createTypedCommand } from "./commander-9Kro0Dl3.mjs";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
//#region src/commands/sync/sync.command.ts
|
|
6
6
|
/**
|
|
@@ -32,7 +32,7 @@ function createSyncCommand() {
|
|
|
32
32
|
description: "Sync local workflows with Keystroke",
|
|
33
33
|
schema: SyncOptionsSchema,
|
|
34
34
|
optionsConfig: SYNC_OPTIONS_CONFIG,
|
|
35
|
-
loadHandler: async () => (await import("./sync.handler-
|
|
35
|
+
loadHandler: async () => (await import("./sync.handler-B1L8I9lF.mjs")).handleSync
|
|
36
36
|
});
|
|
37
37
|
}
|
|
38
38
|
//#endregion
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { P as logger, a as ui, j as throwReportedCliExit, l as isLocalMode, y as toErrorMessage } from "./keystroke.mjs";
|
|
4
|
-
import { i as projects } from "./dist-
|
|
5
|
-
import { a as validateApiKey, i as requireClient } from "./context-
|
|
6
|
-
import { n as deployFromDir } from "./dist-
|
|
7
|
-
import { t as requireWorkflowsDir } from "./resolve-project-
|
|
8
|
-
import { a as runWorkflowBuild, n as renderBuildFailure, r as renderBuildHeader } from "./workflow-build-
|
|
9
|
-
import { t as createBuildProgress } from "./build-progress-
|
|
10
|
-
import { t as createDeployProgress } from "./deploy-progress-
|
|
4
|
+
import { i as projects } from "./dist-DuJjDZIf.mjs";
|
|
5
|
+
import { a as validateApiKey, i as requireClient } from "./context-B2cQ-Nt3.mjs";
|
|
6
|
+
import { n as deployFromDir } from "./dist-Br4m3sFZ.mjs";
|
|
7
|
+
import { t as requireWorkflowsDir } from "./resolve-project-Cj3MFnU0.mjs";
|
|
8
|
+
import { a as runWorkflowBuild, n as renderBuildFailure, r as renderBuildHeader } from "./workflow-build-Bi1Aacc5.mjs";
|
|
9
|
+
import { t as createBuildProgress } from "./build-progress-nYa14iBP.mjs";
|
|
10
|
+
import { t as createDeployProgress } from "./deploy-progress-Dlp9aBDW.mjs";
|
|
11
11
|
//#region src/commands/sync/sync.handler.ts
|
|
12
12
|
async function handleSync(options, ctx) {
|
|
13
13
|
try {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import { n as __exportAll } from "./chunk-
|
|
4
|
-
import { a as descriptionString, c as optionalDescriptionString, d as trimmedNonEmptyStringUnbounded, i as createStructuralSchema, n as credentialSetProxyConfigSchema, o as idNoSpacesString, s as jsonSchemaObject, t as CredentialSetManifestSchema, u as trimmedNonEmptyString } from "./schemas-
|
|
3
|
+
import { n as __exportAll } from "./chunk-CH6r78ws.mjs";
|
|
4
|
+
import { a as descriptionString, c as optionalDescriptionString, d as trimmedNonEmptyStringUnbounded, f as parseCronExpression, i as createStructuralSchema, n as credentialSetProxyConfigSchema, o as idNoSpacesString, s as jsonSchemaObject, t as CredentialSetManifestSchema, u as trimmedNonEmptyString } from "./schemas-D2zfmyC-.mjs";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
import "node:crypto";
|
|
7
7
|
const SHA256HashSchema = z.string().length(64, "Must be 64 characters").regex(/^[a-f0-9]{64}$/i, "Must be hexadecimal").transform((value) => value);
|
|
@@ -20,396 +20,6 @@ z.object({
|
|
|
20
20
|
return data.constant !== void 0 !== (data.exponential !== void 0);
|
|
21
21
|
}, { error: "Retry config must specify exactly one of constant or exponential strategy" });
|
|
22
22
|
//#endregion
|
|
23
|
-
//#region ../../node_modules/.pnpm/cron-schedule@6.0.0/node_modules/cron-schedule/dist/utils.js
|
|
24
|
-
function extractDateElements(date) {
|
|
25
|
-
return {
|
|
26
|
-
second: date.getSeconds(),
|
|
27
|
-
minute: date.getMinutes(),
|
|
28
|
-
hour: date.getHours(),
|
|
29
|
-
day: date.getDate(),
|
|
30
|
-
month: date.getMonth(),
|
|
31
|
-
weekday: date.getDay(),
|
|
32
|
-
year: date.getFullYear()
|
|
33
|
-
};
|
|
34
|
-
}
|
|
35
|
-
function getDaysInMonth(year, month) {
|
|
36
|
-
return new Date(year, month + 1, 0).getDate();
|
|
37
|
-
}
|
|
38
|
-
function getDaysBetweenWeekdays(weekday1, weekday2) {
|
|
39
|
-
if (weekday1 <= weekday2) return weekday2 - weekday1;
|
|
40
|
-
return 6 - weekday1 + weekday2 + 1;
|
|
41
|
-
}
|
|
42
|
-
//#endregion
|
|
43
|
-
//#region ../../node_modules/.pnpm/cron-schedule@6.0.0/node_modules/cron-schedule/dist/cron.js
|
|
44
|
-
var Cron = class {
|
|
45
|
-
constructor({ seconds, minutes, hours, days, months, weekdays }) {
|
|
46
|
-
if (!seconds || seconds.size === 0) throw new Error("There must be at least one allowed second.");
|
|
47
|
-
if (!minutes || minutes.size === 0) throw new Error("There must be at least one allowed minute.");
|
|
48
|
-
if (!hours || hours.size === 0) throw new Error("There must be at least one allowed hour.");
|
|
49
|
-
if (!months || months.size === 0) throw new Error("There must be at least one allowed month.");
|
|
50
|
-
if ((!weekdays || weekdays.size === 0) && (!days || days.size === 0)) throw new Error("There must be at least one allowed day or weekday.");
|
|
51
|
-
this.seconds = Array.from(seconds).sort((a, b) => a - b);
|
|
52
|
-
this.minutes = Array.from(minutes).sort((a, b) => a - b);
|
|
53
|
-
this.hours = Array.from(hours).sort((a, b) => a - b);
|
|
54
|
-
this.days = Array.from(days).sort((a, b) => a - b);
|
|
55
|
-
this.months = Array.from(months).sort((a, b) => a - b);
|
|
56
|
-
this.weekdays = Array.from(weekdays).sort((a, b) => a - b);
|
|
57
|
-
const validateData = (name, data, constraint) => {
|
|
58
|
-
if (data.some((x) => typeof x !== "number" || x % 1 !== 0 || x < constraint.min || x > constraint.max)) throw new Error(`${name} must only consist of integers which are within the range of ${constraint.min} and ${constraint.max}`);
|
|
59
|
-
};
|
|
60
|
-
validateData("seconds", this.seconds, {
|
|
61
|
-
min: 0,
|
|
62
|
-
max: 59
|
|
63
|
-
});
|
|
64
|
-
validateData("minutes", this.minutes, {
|
|
65
|
-
min: 0,
|
|
66
|
-
max: 59
|
|
67
|
-
});
|
|
68
|
-
validateData("hours", this.hours, {
|
|
69
|
-
min: 0,
|
|
70
|
-
max: 23
|
|
71
|
-
});
|
|
72
|
-
validateData("days", this.days, {
|
|
73
|
-
min: 1,
|
|
74
|
-
max: 31
|
|
75
|
-
});
|
|
76
|
-
validateData("months", this.months, {
|
|
77
|
-
min: 0,
|
|
78
|
-
max: 11
|
|
79
|
-
});
|
|
80
|
-
validateData("weekdays", this.weekdays, {
|
|
81
|
-
min: 0,
|
|
82
|
-
max: 6
|
|
83
|
-
});
|
|
84
|
-
this.reversed = {
|
|
85
|
-
seconds: this.seconds.map((x) => x).reverse(),
|
|
86
|
-
minutes: this.minutes.map((x) => x).reverse(),
|
|
87
|
-
hours: this.hours.map((x) => x).reverse(),
|
|
88
|
-
days: this.days.map((x) => x).reverse(),
|
|
89
|
-
months: this.months.map((x) => x).reverse(),
|
|
90
|
-
weekdays: this.weekdays.map((x) => x).reverse()
|
|
91
|
-
};
|
|
92
|
-
}
|
|
93
|
-
/**
|
|
94
|
-
* Find the next or previous hour, starting from the given start hour that matches the hour constraint.
|
|
95
|
-
* startHour itself might also be allowed.
|
|
96
|
-
*/
|
|
97
|
-
findAllowedHour(dir, startHour) {
|
|
98
|
-
return dir === "next" ? this.hours.find((x) => x >= startHour) : this.reversed.hours.find((x) => x <= startHour);
|
|
99
|
-
}
|
|
100
|
-
/**
|
|
101
|
-
* Find the next or previous minute, starting from the given start minute that matches the minute constraint.
|
|
102
|
-
* startMinute itself might also be allowed.
|
|
103
|
-
*/
|
|
104
|
-
findAllowedMinute(dir, startMinute) {
|
|
105
|
-
return dir === "next" ? this.minutes.find((x) => x >= startMinute) : this.reversed.minutes.find((x) => x <= startMinute);
|
|
106
|
-
}
|
|
107
|
-
/**
|
|
108
|
-
* Find the next or previous second, starting from the given start second that matches the second constraint.
|
|
109
|
-
* startSecond itself IS NOT allowed.
|
|
110
|
-
*/
|
|
111
|
-
findAllowedSecond(dir, startSecond) {
|
|
112
|
-
return dir === "next" ? this.seconds.find((x) => x > startSecond) : this.reversed.seconds.find((x) => x < startSecond);
|
|
113
|
-
}
|
|
114
|
-
/**
|
|
115
|
-
* Find the next or previous time, starting from the given start time that matches the hour, minute
|
|
116
|
-
* and second constraints. startTime itself might also be allowed.
|
|
117
|
-
*/
|
|
118
|
-
findAllowedTime(dir, startTime) {
|
|
119
|
-
let hour = this.findAllowedHour(dir, startTime.hour);
|
|
120
|
-
if (hour !== void 0) if (hour === startTime.hour) {
|
|
121
|
-
let minute = this.findAllowedMinute(dir, startTime.minute);
|
|
122
|
-
if (minute !== void 0) if (minute === startTime.minute) {
|
|
123
|
-
const second = this.findAllowedSecond(dir, startTime.second);
|
|
124
|
-
if (second !== void 0) return {
|
|
125
|
-
hour,
|
|
126
|
-
minute,
|
|
127
|
-
second
|
|
128
|
-
};
|
|
129
|
-
minute = this.findAllowedMinute(dir, dir === "next" ? startTime.minute + 1 : startTime.minute - 1);
|
|
130
|
-
if (minute !== void 0) return {
|
|
131
|
-
hour,
|
|
132
|
-
minute,
|
|
133
|
-
second: dir === "next" ? this.seconds[0] : this.reversed.seconds[0]
|
|
134
|
-
};
|
|
135
|
-
} else return {
|
|
136
|
-
hour,
|
|
137
|
-
minute,
|
|
138
|
-
second: dir === "next" ? this.seconds[0] : this.reversed.seconds[0]
|
|
139
|
-
};
|
|
140
|
-
hour = this.findAllowedHour(dir, dir === "next" ? startTime.hour + 1 : startTime.hour - 1);
|
|
141
|
-
if (hour !== void 0) return {
|
|
142
|
-
hour,
|
|
143
|
-
minute: dir === "next" ? this.minutes[0] : this.reversed.minutes[0],
|
|
144
|
-
second: dir === "next" ? this.seconds[0] : this.reversed.seconds[0]
|
|
145
|
-
};
|
|
146
|
-
} else return {
|
|
147
|
-
hour,
|
|
148
|
-
minute: dir === "next" ? this.minutes[0] : this.reversed.minutes[0],
|
|
149
|
-
second: dir === "next" ? this.seconds[0] : this.reversed.seconds[0]
|
|
150
|
-
};
|
|
151
|
-
}
|
|
152
|
-
/**
|
|
153
|
-
* Find the next or previous day in the given month, starting from the given startDay
|
|
154
|
-
* that matches either the day or the weekday constraint. startDay itself might also be allowed.
|
|
155
|
-
*/
|
|
156
|
-
findAllowedDayInMonth(dir, year, month, startDay) {
|
|
157
|
-
var _a, _b;
|
|
158
|
-
if (startDay < 1) throw new Error("startDay must not be smaller than 1.");
|
|
159
|
-
const daysInMonth = getDaysInMonth(year, month);
|
|
160
|
-
const daysRestricted = this.days.length !== 31;
|
|
161
|
-
const weekdaysRestricted = this.weekdays.length !== 7;
|
|
162
|
-
if (!daysRestricted && !weekdaysRestricted) {
|
|
163
|
-
if (startDay > daysInMonth) return dir === "next" ? void 0 : daysInMonth;
|
|
164
|
-
return startDay;
|
|
165
|
-
}
|
|
166
|
-
let allowedDayByDays;
|
|
167
|
-
if (daysRestricted) {
|
|
168
|
-
allowedDayByDays = dir === "next" ? this.days.find((x) => x >= startDay) : this.reversed.days.find((x) => x <= startDay);
|
|
169
|
-
if (allowedDayByDays !== void 0 && allowedDayByDays > daysInMonth) allowedDayByDays = void 0;
|
|
170
|
-
}
|
|
171
|
-
let allowedDayByWeekdays;
|
|
172
|
-
if (weekdaysRestricted) {
|
|
173
|
-
const startWeekday = new Date(year, month, startDay).getDay();
|
|
174
|
-
const nearestAllowedWeekday = dir === "next" ? (_a = this.weekdays.find((x) => x >= startWeekday)) !== null && _a !== void 0 ? _a : this.weekdays[0] : (_b = this.reversed.weekdays.find((x) => x <= startWeekday)) !== null && _b !== void 0 ? _b : this.reversed.weekdays[0];
|
|
175
|
-
if (nearestAllowedWeekday !== void 0) {
|
|
176
|
-
const daysBetweenWeekdays = dir === "next" ? getDaysBetweenWeekdays(startWeekday, nearestAllowedWeekday) : getDaysBetweenWeekdays(nearestAllowedWeekday, startWeekday);
|
|
177
|
-
allowedDayByWeekdays = dir === "next" ? startDay + daysBetweenWeekdays : startDay - daysBetweenWeekdays;
|
|
178
|
-
if (allowedDayByWeekdays > daysInMonth || allowedDayByWeekdays < 1) allowedDayByWeekdays = void 0;
|
|
179
|
-
}
|
|
180
|
-
}
|
|
181
|
-
if (allowedDayByDays !== void 0 && allowedDayByWeekdays !== void 0) return dir === "next" ? Math.min(allowedDayByDays, allowedDayByWeekdays) : Math.max(allowedDayByDays, allowedDayByWeekdays);
|
|
182
|
-
if (allowedDayByDays !== void 0) return allowedDayByDays;
|
|
183
|
-
if (allowedDayByWeekdays !== void 0) return allowedDayByWeekdays;
|
|
184
|
-
}
|
|
185
|
-
/** Gets the next date starting from the given start date or now. */
|
|
186
|
-
getNextDate(startDate = /* @__PURE__ */ new Date()) {
|
|
187
|
-
const startDateElements = extractDateElements(startDate);
|
|
188
|
-
let minYear = startDateElements.year;
|
|
189
|
-
let startIndexMonth = this.months.findIndex((x) => x >= startDateElements.month);
|
|
190
|
-
if (startIndexMonth === -1) {
|
|
191
|
-
startIndexMonth = 0;
|
|
192
|
-
minYear++;
|
|
193
|
-
}
|
|
194
|
-
const maxIterations = this.months.length * 5;
|
|
195
|
-
for (let i = 0; i < maxIterations; i++) {
|
|
196
|
-
const year = minYear + Math.floor((startIndexMonth + i) / this.months.length);
|
|
197
|
-
const month = this.months[(startIndexMonth + i) % this.months.length];
|
|
198
|
-
const isStartMonth = year === startDateElements.year && month === startDateElements.month;
|
|
199
|
-
let day = this.findAllowedDayInMonth("next", year, month, isStartMonth ? startDateElements.day : 1);
|
|
200
|
-
let isStartDay = isStartMonth && day === startDateElements.day;
|
|
201
|
-
if (day !== void 0 && isStartDay) {
|
|
202
|
-
const nextTime = this.findAllowedTime("next", startDateElements);
|
|
203
|
-
if (nextTime !== void 0) return new Date(year, month, day, nextTime.hour, nextTime.minute, nextTime.second);
|
|
204
|
-
day = this.findAllowedDayInMonth("next", year, month, day + 1);
|
|
205
|
-
isStartDay = false;
|
|
206
|
-
}
|
|
207
|
-
if (day !== void 0 && !isStartDay) return new Date(year, month, day, this.hours[0], this.minutes[0], this.seconds[0]);
|
|
208
|
-
}
|
|
209
|
-
throw new Error("No valid next date was found.");
|
|
210
|
-
}
|
|
211
|
-
/** Gets the specified amount of future dates starting from the given start date or now. */
|
|
212
|
-
getNextDates(amount, startDate) {
|
|
213
|
-
const dates = [];
|
|
214
|
-
let nextDate;
|
|
215
|
-
for (let i = 0; i < amount; i++) {
|
|
216
|
-
nextDate = this.getNextDate(nextDate !== null && nextDate !== void 0 ? nextDate : startDate);
|
|
217
|
-
dates.push(nextDate);
|
|
218
|
-
}
|
|
219
|
-
return dates;
|
|
220
|
-
}
|
|
221
|
-
/**
|
|
222
|
-
* Get an ES6 compatible iterator which iterates over the next dates starting from startDate or now.
|
|
223
|
-
* The iterator runs until the optional endDate is reached or forever.
|
|
224
|
-
*/
|
|
225
|
-
*getNextDatesIterator(startDate, endDate) {
|
|
226
|
-
let nextDate;
|
|
227
|
-
while (true) {
|
|
228
|
-
nextDate = this.getNextDate(nextDate !== null && nextDate !== void 0 ? nextDate : startDate);
|
|
229
|
-
if (endDate && endDate.getTime() < nextDate.getTime()) return;
|
|
230
|
-
yield nextDate;
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
/** Gets the previous date starting from the given start date or now. */
|
|
234
|
-
getPrevDate(startDate = /* @__PURE__ */ new Date()) {
|
|
235
|
-
const startDateElements = extractDateElements(startDate);
|
|
236
|
-
let maxYear = startDateElements.year;
|
|
237
|
-
let startIndexMonth = this.reversed.months.findIndex((x) => x <= startDateElements.month);
|
|
238
|
-
if (startIndexMonth === -1) {
|
|
239
|
-
startIndexMonth = 0;
|
|
240
|
-
maxYear--;
|
|
241
|
-
}
|
|
242
|
-
const maxIterations = this.reversed.months.length * 5;
|
|
243
|
-
for (let i = 0; i < maxIterations; i++) {
|
|
244
|
-
const year = maxYear - Math.floor((startIndexMonth + i) / this.reversed.months.length);
|
|
245
|
-
const month = this.reversed.months[(startIndexMonth + i) % this.reversed.months.length];
|
|
246
|
-
const isStartMonth = year === startDateElements.year && month === startDateElements.month;
|
|
247
|
-
let day = this.findAllowedDayInMonth("prev", year, month, isStartMonth ? startDateElements.day : getDaysInMonth(year, month));
|
|
248
|
-
let isStartDay = isStartMonth && day === startDateElements.day;
|
|
249
|
-
if (day !== void 0 && isStartDay) {
|
|
250
|
-
const prevTime = this.findAllowedTime("prev", startDateElements);
|
|
251
|
-
if (prevTime !== void 0) return new Date(year, month, day, prevTime.hour, prevTime.minute, prevTime.second);
|
|
252
|
-
if (day > 1) {
|
|
253
|
-
day = this.findAllowedDayInMonth("prev", year, month, day - 1);
|
|
254
|
-
isStartDay = false;
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
if (day !== void 0 && !isStartDay) return new Date(year, month, day, this.reversed.hours[0], this.reversed.minutes[0], this.reversed.seconds[0]);
|
|
258
|
-
}
|
|
259
|
-
throw new Error("No valid previous date was found.");
|
|
260
|
-
}
|
|
261
|
-
/** Gets the specified amount of previous dates starting from the given start date or now. */
|
|
262
|
-
getPrevDates(amount, startDate) {
|
|
263
|
-
const dates = [];
|
|
264
|
-
let prevDate;
|
|
265
|
-
for (let i = 0; i < amount; i++) {
|
|
266
|
-
prevDate = this.getPrevDate(prevDate !== null && prevDate !== void 0 ? prevDate : startDate);
|
|
267
|
-
dates.push(prevDate);
|
|
268
|
-
}
|
|
269
|
-
return dates;
|
|
270
|
-
}
|
|
271
|
-
/**
|
|
272
|
-
* Get an ES6 compatible iterator which iterates over the previous dates starting from startDate or now.
|
|
273
|
-
* The iterator runs until the optional endDate is reached or forever.
|
|
274
|
-
*/
|
|
275
|
-
*getPrevDatesIterator(startDate, endDate) {
|
|
276
|
-
let prevDate;
|
|
277
|
-
while (true) {
|
|
278
|
-
prevDate = this.getPrevDate(prevDate !== null && prevDate !== void 0 ? prevDate : startDate);
|
|
279
|
-
if (endDate && endDate.getTime() > prevDate.getTime()) return;
|
|
280
|
-
yield prevDate;
|
|
281
|
-
}
|
|
282
|
-
}
|
|
283
|
-
/** Returns true when there is a cron date at the given date. */
|
|
284
|
-
matchDate(date) {
|
|
285
|
-
const { second, minute, hour, day, month, weekday } = extractDateElements(date);
|
|
286
|
-
if (this.seconds.indexOf(second) === -1 || this.minutes.indexOf(minute) === -1 || this.hours.indexOf(hour) === -1 || this.months.indexOf(month) === -1) return false;
|
|
287
|
-
if (this.days.length !== 31 && this.weekdays.length !== 7) return this.days.indexOf(day) !== -1 || this.weekdays.indexOf(weekday) !== -1;
|
|
288
|
-
return this.days.indexOf(day) !== -1 && this.weekdays.indexOf(weekday) !== -1;
|
|
289
|
-
}
|
|
290
|
-
};
|
|
291
|
-
//#endregion
|
|
292
|
-
//#region ../../node_modules/.pnpm/cron-schedule@6.0.0/node_modules/cron-schedule/dist/cron-parser.js
|
|
293
|
-
const secondConstraint = {
|
|
294
|
-
min: 0,
|
|
295
|
-
max: 59
|
|
296
|
-
};
|
|
297
|
-
const minuteConstraint = {
|
|
298
|
-
min: 0,
|
|
299
|
-
max: 59
|
|
300
|
-
};
|
|
301
|
-
const hourConstraint = {
|
|
302
|
-
min: 0,
|
|
303
|
-
max: 23
|
|
304
|
-
};
|
|
305
|
-
const dayConstraint = {
|
|
306
|
-
min: 1,
|
|
307
|
-
max: 31
|
|
308
|
-
};
|
|
309
|
-
const monthConstraint = {
|
|
310
|
-
min: 1,
|
|
311
|
-
max: 12,
|
|
312
|
-
aliases: {
|
|
313
|
-
jan: "1",
|
|
314
|
-
feb: "2",
|
|
315
|
-
mar: "3",
|
|
316
|
-
apr: "4",
|
|
317
|
-
may: "5",
|
|
318
|
-
jun: "6",
|
|
319
|
-
jul: "7",
|
|
320
|
-
aug: "8",
|
|
321
|
-
sep: "9",
|
|
322
|
-
oct: "10",
|
|
323
|
-
nov: "11",
|
|
324
|
-
dec: "12"
|
|
325
|
-
}
|
|
326
|
-
};
|
|
327
|
-
const weekdayConstraint = {
|
|
328
|
-
min: 0,
|
|
329
|
-
max: 7,
|
|
330
|
-
aliases: {
|
|
331
|
-
mon: "1",
|
|
332
|
-
tue: "2",
|
|
333
|
-
wed: "3",
|
|
334
|
-
thu: "4",
|
|
335
|
-
fri: "5",
|
|
336
|
-
sat: "6",
|
|
337
|
-
sun: "7"
|
|
338
|
-
}
|
|
339
|
-
};
|
|
340
|
-
const timeNicknames = {
|
|
341
|
-
"@yearly": "0 0 1 1 *",
|
|
342
|
-
"@annually": "0 0 1 1 *",
|
|
343
|
-
"@monthly": "0 0 1 * *",
|
|
344
|
-
"@weekly": "0 0 * * 0",
|
|
345
|
-
"@daily": "0 0 * * *",
|
|
346
|
-
"@hourly": "0 * * * *",
|
|
347
|
-
"@minutely": "* * * * *"
|
|
348
|
-
};
|
|
349
|
-
function parseElement(element, constraint) {
|
|
350
|
-
const result = /* @__PURE__ */ new Set();
|
|
351
|
-
if (element === "*") {
|
|
352
|
-
for (let i = constraint.min; i <= constraint.max; i = i + 1) result.add(i);
|
|
353
|
-
return result;
|
|
354
|
-
}
|
|
355
|
-
const listElements = element.split(",");
|
|
356
|
-
if (listElements.length > 1) {
|
|
357
|
-
for (const listElement of listElements) {
|
|
358
|
-
const parsedListElement = parseElement(listElement, constraint);
|
|
359
|
-
for (const x of parsedListElement) result.add(x);
|
|
360
|
-
}
|
|
361
|
-
return result;
|
|
362
|
-
}
|
|
363
|
-
const parseSingleElement = (singleElement) => {
|
|
364
|
-
var _a, _b;
|
|
365
|
-
singleElement = (_b = (_a = constraint.aliases) === null || _a === void 0 ? void 0 : _a[singleElement.toLowerCase()]) !== null && _b !== void 0 ? _b : singleElement;
|
|
366
|
-
const parsedElement = Number.parseInt(singleElement, 10);
|
|
367
|
-
if (Number.isNaN(parsedElement)) throw new Error(`Failed to parse ${element}: ${singleElement} is NaN.`);
|
|
368
|
-
if (parsedElement < constraint.min || parsedElement > constraint.max) throw new Error(`Failed to parse ${element}: ${singleElement} is outside of constraint range of ${constraint.min} - ${constraint.max}.`);
|
|
369
|
-
return parsedElement;
|
|
370
|
-
};
|
|
371
|
-
const rangeSegments = /^(([0-9a-zA-Z]+)-([0-9a-zA-Z]+)|\*)(\/([0-9]+))?$/.exec(element);
|
|
372
|
-
if (rangeSegments === null) {
|
|
373
|
-
result.add(parseSingleElement(element));
|
|
374
|
-
return result;
|
|
375
|
-
}
|
|
376
|
-
let parsedStart = rangeSegments[1] === "*" ? constraint.min : parseSingleElement(rangeSegments[2]);
|
|
377
|
-
const parsedEnd = rangeSegments[1] === "*" ? constraint.max : parseSingleElement(rangeSegments[3]);
|
|
378
|
-
if (constraint === weekdayConstraint && parsedStart === 7 && parsedEnd !== 7) parsedStart = 0;
|
|
379
|
-
if (parsedStart > parsedEnd) throw new Error(`Failed to parse ${element}: Invalid range (start: ${parsedStart}, end: ${parsedEnd}).`);
|
|
380
|
-
const step = rangeSegments[5];
|
|
381
|
-
let parsedStep = 1;
|
|
382
|
-
if (step !== void 0) {
|
|
383
|
-
parsedStep = Number.parseInt(step, 10);
|
|
384
|
-
if (Number.isNaN(parsedStep)) throw new Error(`Failed to parse step: ${step} is NaN.`);
|
|
385
|
-
if (parsedStep < 1) throw new Error(`Failed to parse step: Expected ${step} to be greater than 0.`);
|
|
386
|
-
}
|
|
387
|
-
for (let i = parsedStart; i <= parsedEnd; i = i + parsedStep) result.add(i);
|
|
388
|
-
return result;
|
|
389
|
-
}
|
|
390
|
-
/** Parses a cron expression into a Cron instance. */
|
|
391
|
-
function parseCronExpression(cronExpression) {
|
|
392
|
-
var _a;
|
|
393
|
-
if (typeof cronExpression !== "string") throw new TypeError("Invalid cron expression: must be of type string.");
|
|
394
|
-
cronExpression = (_a = timeNicknames[cronExpression.toLowerCase()]) !== null && _a !== void 0 ? _a : cronExpression;
|
|
395
|
-
const elements = cronExpression.split(" ").filter((elem) => elem.length > 0);
|
|
396
|
-
if (elements.length < 5 || elements.length > 6) throw new Error("Invalid cron expression: expected 5 or 6 elements.");
|
|
397
|
-
const rawSeconds = elements.length === 6 ? elements[0] : "0";
|
|
398
|
-
const rawMinutes = elements.length === 6 ? elements[1] : elements[0];
|
|
399
|
-
const rawHours = elements.length === 6 ? elements[2] : elements[1];
|
|
400
|
-
const rawDays = elements.length === 6 ? elements[3] : elements[2];
|
|
401
|
-
const rawMonths = elements.length === 6 ? elements[4] : elements[3];
|
|
402
|
-
const rawWeekdays = elements.length === 6 ? elements[5] : elements[4];
|
|
403
|
-
return new Cron({
|
|
404
|
-
seconds: parseElement(rawSeconds, secondConstraint),
|
|
405
|
-
minutes: parseElement(rawMinutes, minuteConstraint),
|
|
406
|
-
hours: parseElement(rawHours, hourConstraint),
|
|
407
|
-
days: parseElement(rawDays, dayConstraint),
|
|
408
|
-
months: new Set(Array.from(parseElement(rawMonths, monthConstraint)).map((x) => x - 1)),
|
|
409
|
-
weekdays: new Set(Array.from(parseElement(rawWeekdays, weekdayConstraint)).map((x) => x % 7))
|
|
410
|
-
});
|
|
411
|
-
}
|
|
412
|
-
//#endregion
|
|
413
23
|
//#region ../../packages/core/src/shared/schedule.ts
|
|
414
24
|
/**
|
|
415
25
|
* shared/schedule.ts
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { r as getKeystrokeProjectPath } from "./paths-JzzFkXQA-CEipIeVl.mjs";
|
|
4
|
-
import "./dist-
|
|
5
|
-
import { t as readCredentialKeysFromSchemaObject } from "./read-credential-keys-77a91T8M-
|
|
4
|
+
import "./dist-DuJjDZIf.mjs";
|
|
5
|
+
import { t as readCredentialKeysFromSchemaObject } from "./read-credential-keys-77a91T8M-aLuQvlIq.mjs";
|
|
6
6
|
import path from "node:path";
|
|
7
7
|
import { mkdir, writeFile } from "node:fs/promises";
|
|
8
8
|
import { pathToFileURL } from "node:url";
|
|
@@ -111,7 +111,7 @@ async function buildTaskTargetFile(options) {
|
|
|
111
111
|
return builtTasks;
|
|
112
112
|
}
|
|
113
113
|
async function bundleTaskTargetModule(options) {
|
|
114
|
-
const [{ rolldown }, { createEnvAccessPlugin, formatEnvAccessError }] = await Promise.all([import("rolldown"), import("./detect-env-access-CwkOYeYM-
|
|
114
|
+
const [{ rolldown }, { createEnvAccessPlugin, formatEnvAccessError }] = await Promise.all([import("rolldown"), import("./detect-env-access-CwkOYeYM-D4aTZv4R.mjs").then((n) => n.n).then((n) => n.n)]);
|
|
115
115
|
const entryId = "\0virtual:task-target-entry";
|
|
116
116
|
const trackedDependencies = /* @__PURE__ */ new Set();
|
|
117
117
|
const envViolations = [];
|
|
@@ -218,7 +218,7 @@ async function attachTaskTargetTriggers(options) {
|
|
|
218
218
|
options.artifact.triggers.push(...buildTaskTriggerArtifactsWithoutBundles(options.entry.taskMetadata.triggers, options.artifact.task.taskId, options.artifact.task.taskName));
|
|
219
219
|
return [];
|
|
220
220
|
}
|
|
221
|
-
const { buildTriggerArtifacts } = await import("./trigger-artifacts-BcRScRSp-
|
|
221
|
+
const { buildTriggerArtifacts } = await import("./trigger-artifacts-BcRScRSp-C-JBJ6y8.mjs").then((n) => n.n);
|
|
222
222
|
const triggerResult = await buildTriggerArtifacts(options.entry.taskMetadata.triggers, options.artifact.task.taskId, options.artifact.task.taskName, options.projectRoot, {
|
|
223
223
|
workflowExportName: options.entry.source.localExportName,
|
|
224
224
|
workflowFilePath: options.entry.runtimeBundlePath
|
|
@@ -319,7 +319,7 @@ function createPreparedTaskTarget(artifact, triggers) {
|
|
|
319
319
|
};
|
|
320
320
|
}
|
|
321
321
|
async function tryParseTaskBuildManifest(manifest) {
|
|
322
|
-
const { TaskBuildManifestSchema } = await import("./task-
|
|
322
|
+
const { TaskBuildManifestSchema } = await import("./task-BWuIKWh4.mjs").then((n) => n.t);
|
|
323
323
|
const result = TaskBuildManifestSchema.safeParse(manifest);
|
|
324
324
|
return result.success ? result.data : null;
|
|
325
325
|
}
|
package/dist/{task-target-deploy-dQYnMO8n-CeTmRcDw.mjs → task-target-deploy-dQYnMO8n-d2vdeqXH.mjs}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { n as SHA256HashSchema } from "./common-AK0q0Oz0.mjs";
|
|
4
4
|
import { createHash } from "node:crypto";
|
|
5
5
|
//#region ../../packages/shared-types/src/deployments/api/snapshot-payload.ts
|
|
6
6
|
function sortObjectKeysDeep(value) {
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
import { r as getKeystrokeProjectPath } from "./paths-JzzFkXQA-CEipIeVl.mjs";
|
|
4
4
|
import "./default-urls-BoSm4s9C.mjs";
|
|
5
|
-
import "./dist-
|
|
5
|
+
import "./dist-DuJjDZIf.mjs";
|
|
6
6
|
import { n as findProjectRoot, t as assertWorkflowProjectRoot } from "./project-config-DudGRFPO.mjs";
|
|
7
|
-
import { t as resolveCliCredentials } from "./resolve-cli-credentials-
|
|
7
|
+
import { t as resolveCliCredentials } from "./resolve-cli-credentials-DaMDaamj.mjs";
|
|
8
8
|
import path from "node:path";
|
|
9
9
|
import { mkdir, readFile, writeFile } from "node:fs/promises";
|
|
10
10
|
import { spawnSync } from "node:child_process";
|
|
@@ -119,7 +119,7 @@ function restartStage(options, projectRoot, stage) {
|
|
|
119
119
|
}
|
|
120
120
|
async function runBuildPhase(options, projectRoot) {
|
|
121
121
|
const projectConfig = await assertWorkflowProjectRoot(projectRoot);
|
|
122
|
-
const { buildTaskTargetEntries } = await import("./task-target-build-
|
|
122
|
+
const { buildTaskTargetEntries } = await import("./task-target-build-CTgl4L42.mjs");
|
|
123
123
|
await writeBuildDescriptor(projectRoot, {
|
|
124
124
|
projectRoot,
|
|
125
125
|
projectConfig,
|
|
@@ -132,7 +132,7 @@ async function runBuildPhase(options, projectRoot) {
|
|
|
132
132
|
}
|
|
133
133
|
async function runPreparePhase(projectRoot) {
|
|
134
134
|
const buildDescriptor = await readBuildDescriptor(projectRoot);
|
|
135
|
-
const { prepareTaskTargetBuiltTasks } = await import("./task-target-build-
|
|
135
|
+
const { prepareTaskTargetBuiltTasks } = await import("./task-target-build-CTgl4L42.mjs");
|
|
136
136
|
const prepareResult = await prepareTaskTargetBuiltTasks({
|
|
137
137
|
builtTasks: buildDescriptor.builtTasks,
|
|
138
138
|
projectRoot
|
|
@@ -163,11 +163,11 @@ async function resolveDeployAuthOptions(options) {
|
|
|
163
163
|
}
|
|
164
164
|
async function runDeployPhase(options, projectRoot) {
|
|
165
165
|
const descriptor = await readDescriptor(projectRoot);
|
|
166
|
-
const { createDeployClient } = await import("./deploy-
|
|
166
|
+
const { createDeployClient } = await import("./deploy-BURTx92e.mjs");
|
|
167
167
|
const client = createDeployClient(await resolveDeployAuthOptions(options));
|
|
168
168
|
const auth = await client.public.auth.validate();
|
|
169
169
|
if (auth.organizationId !== descriptor.projectConfig.organizationId) throw new Error(`Project organization mismatch: config=${descriptor.projectConfig.organizationId} auth=${auth.organizationId}`);
|
|
170
|
-
const { deployTaskTargets } = await import("./task-target-deploy-
|
|
170
|
+
const { deployTaskTargets } = await import("./task-target-deploy-DeUyfi9H.mjs");
|
|
171
171
|
const result = await deployTaskTargets({
|
|
172
172
|
preparedTasks: descriptor.preparedTasks,
|
|
173
173
|
client,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
import { a as ui } from "./keystroke.mjs";
|
|
4
4
|
import { n as JsonOptionSchema, t as JSON_OPTION_CONFIG } from "./output-BWcVRt-T.mjs";
|
|
5
|
-
import { t as createTypedCommand } from "./commander-
|
|
5
|
+
import { t as createTypedCommand } from "./commander-9Kro0Dl3.mjs";
|
|
6
6
|
import { z } from "zod";
|
|
7
7
|
//#region src/commands/test/test.command.ts
|
|
8
8
|
const TestOptionsSchema = JsonOptionSchema;
|
|
@@ -63,7 +63,7 @@ function createTestCommand() {
|
|
|
63
63
|
description: "Agent tool name from the built manifest",
|
|
64
64
|
key: "toolName"
|
|
65
65
|
},
|
|
66
|
-
loadHandler: async () => (await import("./tool.handler-
|
|
66
|
+
loadHandler: async () => (await import("./tool.handler-BHS5Z4J_.mjs")).handleTestTool
|
|
67
67
|
})]
|
|
68
68
|
});
|
|
69
69
|
cmd.enablePositionalOptions();
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { D as CliExitError, a as ui, l as isLocalMode, y as toErrorMessage } from "./keystroke.mjs";
|
|
4
|
-
import { i as projects } from "./dist-
|
|
4
|
+
import { i as projects } from "./dist-DuJjDZIf.mjs";
|
|
5
5
|
import { t as assertWorkflowProjectRoot } from "./project-config-DudGRFPO.mjs";
|
|
6
|
-
import { i as requireClient, t as assertProjectConfigMatchesAuthenticatedOrg } from "./context-
|
|
7
|
-
import { o as readWorkflowsFromDisk, s as uploadTestBundle } from "./dist-
|
|
8
|
-
import { t as requireWorkflowsDir } from "./resolve-project-
|
|
9
|
-
import { a as runWorkflowBuild, t as WorkflowNotFoundError } from "./workflow-build-
|
|
10
|
-
import { r as isUnknownSchema } from "./schema-display-
|
|
11
|
-
import { t as createBuildProgress } from "./build-progress-
|
|
12
|
-
import { t as withErrorBoundary } from "./error-boundary-
|
|
13
|
-
import { a as tryReadExistingInputSchema, n as resolveInput, o as validateInputOrExit, t as pollForCompletion } from "./run-polling-
|
|
6
|
+
import { i as requireClient, t as assertProjectConfigMatchesAuthenticatedOrg } from "./context-B2cQ-Nt3.mjs";
|
|
7
|
+
import { o as readWorkflowsFromDisk, s as uploadTestBundle } from "./dist-Br4m3sFZ.mjs";
|
|
8
|
+
import { t as requireWorkflowsDir } from "./resolve-project-Cj3MFnU0.mjs";
|
|
9
|
+
import { a as runWorkflowBuild, t as WorkflowNotFoundError } from "./workflow-build-Bi1Aacc5.mjs";
|
|
10
|
+
import { r as isUnknownSchema } from "./schema-display-XrRCdFL0.mjs";
|
|
11
|
+
import { t as createBuildProgress } from "./build-progress-nYa14iBP.mjs";
|
|
12
|
+
import { t as withErrorBoundary } from "./error-boundary-DVZipk-A.mjs";
|
|
13
|
+
import { a as tryReadExistingInputSchema, n as resolveInput, o as validateInputOrExit, t as pollForCompletion } from "./run-polling-3XOGl4hh.mjs";
|
|
14
14
|
//#region src/lib/format.ts
|
|
15
15
|
function formatBytes(bytes) {
|
|
16
16
|
if (bytes < 1024) return `${bytes} B`;
|