@kici-dev/compiler 0.1.15 → 0.1.17
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/auth/headless-detect.js +1 -1
- package/dist/cli-banner.js +1 -1
- package/dist/cli.d.ts +9 -1
- package/dist/cli.js +251 -183
- package/dist/commands/approve.d.ts +23 -0
- package/dist/commands/approve.js +46 -0
- package/dist/commands/compile.js +6 -4
- package/dist/commands/diagnostics.d.ts +7 -0
- package/dist/commands/diagnostics.js +58 -0
- package/dist/commands/docs.js +3 -3
- package/dist/commands/drain-worker.js +1 -1
- package/dist/commands/endpoints.js +2 -2
- package/dist/commands/fixture.js +1 -1
- package/dist/commands/held-run-client.d.ts +26 -0
- package/dist/commands/held-run-client.js +98 -0
- package/dist/commands/held-run-resolve.d.ts +45 -0
- package/dist/commands/held-run-resolve.js +53 -0
- package/dist/commands/hook.js +2 -2
- package/dist/commands/index.d.ts +20 -4
- package/dist/commands/index.js +12 -4
- package/dist/commands/init.js +3 -3
- package/dist/commands/login.d.ts +0 -2
- package/dist/commands/login.js +1 -3
- package/dist/commands/logout.js +1 -1
- package/dist/commands/orchestrators.d.ts +25 -0
- package/dist/commands/orchestrators.js +115 -0
- package/dist/commands/org.js +1 -1
- package/dist/commands/reject.d.ts +25 -0
- package/dist/commands/reject.js +49 -0
- package/dist/commands/run.d.ts +2 -9
- package/dist/commands/run.js +257 -316
- package/dist/commands/runs/cancel.d.ts +6 -0
- package/dist/commands/runs/cancel.js +32 -0
- package/dist/commands/runs/list.d.ts +6 -0
- package/dist/commands/runs/list.js +49 -0
- package/dist/commands/runs/logs.d.ts +7 -0
- package/dist/commands/runs/logs.js +67 -0
- package/dist/commands/runs/rerun.d.ts +5 -0
- package/dist/commands/runs/rerun.js +21 -0
- package/dist/commands/runs/show.d.ts +5 -0
- package/dist/commands/runs/show.js +65 -0
- package/dist/commands/secrets-list.d.ts +7 -9
- package/dist/commands/secrets-list.js +40 -64
- package/dist/commands/test.d.ts +4 -0
- package/dist/commands/test.js +2 -2
- package/dist/commands/types.d.ts +3 -5
- package/dist/commands/types.js +14 -38
- package/dist/commands/verify-attestation.d.ts +12 -0
- package/dist/commands/verify-attestation.js +69 -0
- package/dist/commands/watch.js +2 -2
- package/dist/commands/workflows.js +14 -34
- package/dist/errors/capability-gap.js +1 -1
- package/dist/errors/formatter.js +1 -1
- package/dist/errors/index.js +1 -1
- package/dist/execution/executor.js +3 -3
- package/dist/execution/index.js +1 -1
- package/dist/execution/sdk-alias.js +2 -2
- package/dist/execution/ts-loader.js +1 -1
- package/dist/fixtures/compiler.js +3 -3
- package/dist/fixtures/defaults/index.js +3 -3
- package/dist/format.js +1 -1
- package/dist/generators/secrets-dts.js +2 -2
- package/dist/hooks/detector.js +2 -2
- package/dist/hooks/index.js +1 -1
- package/dist/hooks/installer.js +2 -2
- package/dist/hooks/templates.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/llm-context/llms-full.txt +1180 -131
- package/dist/llm-context/llms.txt +6 -2
- package/dist/local-executor/dag-scheduler.js +1 -1
- package/dist/local-executor/index.js +2 -2
- package/dist/local-executor/job-runner.js +38 -17
- package/dist/local-executor/materializer.js +2 -2
- package/dist/local-executor/output-streamer.js +1 -1
- package/dist/local-executor/payload-generator.js +1 -1
- package/dist/local-executor/picker.js +1 -1
- package/dist/local-executor/secret-loader.js +2 -2
- package/dist/local-executor/to-event-payload.js +1 -1
- package/dist/local-executor/types.js +1 -1
- package/dist/local-executor/workflow-lock.js +0 -0
- package/dist/lockfile/generator.d.ts +7 -5
- package/dist/lockfile/generator.js +38 -23
- package/dist/lockfile/hash-files.js +2 -2
- package/dist/lockfile/hasher.js +1 -1
- package/dist/lockfile/index.js +1 -1
- package/dist/lockfile/purity-analyzer.js +1 -1
- package/dist/postinstall.js +2 -2
- package/dist/provenance-trust-root.d.ts +14 -0
- package/dist/provenance-trust-root.js +49 -0
- package/dist/remote/config.d.ts +6 -2
- package/dist/remote/config.js +8 -5
- package/dist/remote/dashboard-client.d.ts +92 -0
- package/dist/remote/dashboard-client.js +168 -0
- package/dist/remote/encryption.js +3 -4
- package/dist/remote/history.js +2 -2
- package/dist/remote/oauth.js +1 -1
- package/dist/remote/oidc-discovery.js +1 -1
- package/dist/remote/output/json.js +1 -1
- package/dist/remote/output/junit.js +1 -1
- package/dist/remote/output/streaming.js +1 -1
- package/dist/remote/output/summary.js +1 -1
- package/dist/remote/platform-client.d.ts +142 -0
- package/dist/remote/platform-client.js +187 -0
- package/dist/remote/prod-defaults.js +1 -1
- package/dist/remote/render.d.ts +11 -0
- package/dist/remote/render.js +48 -0
- package/dist/remote/secret-upload.js +1 -1
- package/dist/remote/uploader.d.ts +9 -0
- package/dist/remote/uploader.js +52 -5
- package/dist/templates/agents-md.d.ts +1 -1
- package/dist/templates/agents-md.js +8 -3
- package/dist/templates/index.js +2 -2
- package/dist/templates/package-json.js +4 -5
- package/dist/templates/tsconfig-json.js +1 -1
- package/dist/templates/workflows/hello-world.js +2 -2
- package/dist/templates/workflows/hello-world.ts +1 -1
- package/dist/templates/workflows/pr-checks.js +3 -3
- package/dist/templates/workflows/pr-checks.ts +2 -2
- package/dist/test-runner/dry-run.js +1 -1
- package/dist/test-runner/event-types.js +1 -1
- package/dist/test-runner/git-detector.js +2 -2
- package/dist/test-runner/index.js +1 -1
- package/dist/test-runner/job-executor.js +3 -3
- package/dist/test-runner/output-formatter.js +1 -1
- package/dist/test-runner/payload-builder.js +1 -1
- package/dist/test-runner/rule-evaluator.js +1 -1
- package/dist/test-runner/secrets-file.js +2 -2
- package/dist/test-runner/step-context.js +11 -7
- package/dist/types.d.ts +24 -6
- package/dist/types.js +2 -1
- package/dist/validation/index.js +1 -1
- package/dist/validation/validator.js +1 -1
- package/dist/workflows/hello-world.ts +1 -1
- package/dist/workflows/pr-checks.ts +2 -2
- package/package.json +5 -4
- package/sbom.spdx.json +68 -38
- package/dist/commands/cancel.js +0 -124
- package/dist/commands/status.js +0 -212
- package/dist/remote/client.js +0 -203
- package/dist/remote/observer.js +0 -174
- /package/dist/{chunk-gOLHoazu.js → chunk-BTugEXQM.js} +0 -0
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import "../chunk-BTugEXQM.js";
|
|
2
|
+
import { listHeldRunsForRun, postReject, resolveHeldRunContext } from "./held-run-client.js";
|
|
3
|
+
import { resolveHeldRunId } from "./held-run-resolve.js";
|
|
4
|
+
import pc from "picocolors";
|
|
5
|
+
import { logger, toErrorMessage } from "@kici-dev/core";
|
|
6
|
+
//#region src/commands/reject.ts
|
|
7
|
+
/**
|
|
8
|
+
* kici reject command
|
|
9
|
+
*
|
|
10
|
+
* Rejects a held approval gate for a run (requires `--reason`). Resolves the
|
|
11
|
+
* held element by `--job` / `--step` (or the sole pending hold), then records
|
|
12
|
+
* the rejection via the Platform dashboard API (PAT auth).
|
|
13
|
+
*/
|
|
14
|
+
/**
|
|
15
|
+
* Reject a held approval gate.
|
|
16
|
+
*
|
|
17
|
+
* @param runId - The run whose hold to reject.
|
|
18
|
+
* @param options - Job/step filters plus the required reason.
|
|
19
|
+
* @returns true on success, false on error.
|
|
20
|
+
*/
|
|
21
|
+
async function rejectCommand(runId, options = {}) {
|
|
22
|
+
try {
|
|
23
|
+
if (!options.reason) {
|
|
24
|
+
logger.error(pc.red("A rejection reason is required. Pass --reason <text>."));
|
|
25
|
+
return false;
|
|
26
|
+
}
|
|
27
|
+
const ctx = await resolveHeldRunContext();
|
|
28
|
+
if (!ctx) return false;
|
|
29
|
+
const resolution = resolveHeldRunId(await listHeldRunsForRun(ctx, runId), {
|
|
30
|
+
job: options.job,
|
|
31
|
+
step: options.step
|
|
32
|
+
});
|
|
33
|
+
if (!resolution.ok) {
|
|
34
|
+
logger.error(pc.red(resolution.error));
|
|
35
|
+
return false;
|
|
36
|
+
}
|
|
37
|
+
logger.info(`Rejecting held run ${pc.cyan(resolution.heldRunId)} for run ${pc.cyan(runId)}...`);
|
|
38
|
+
if (!await postReject(ctx, resolution.heldRunId, options.reason)) return false;
|
|
39
|
+
logger.info(pc.yellow("Rejection recorded. The held element will fail."));
|
|
40
|
+
return true;
|
|
41
|
+
} catch (error) {
|
|
42
|
+
logger.error(pc.red(`Error: ${toErrorMessage(error)}`));
|
|
43
|
+
return false;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
//#endregion
|
|
47
|
+
export { rejectCommand };
|
|
48
|
+
|
|
49
|
+
//# sourceMappingURL=reject.js.map
|
package/dist/commands/run.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import type { RunLocalOptions } from '../local-executor/types.js';
|
|
2
|
-
import {
|
|
3
|
-
import type { RemoteRunOptions, RemoteRunResult } from './test.js';
|
|
2
|
+
import type { RemoteRunOptions } from './test.js';
|
|
4
3
|
/**
|
|
5
4
|
* Run a workflow locally using the local executor.
|
|
6
5
|
* Thin wrapper that delegates to executeLocal from local-executor.
|
|
@@ -9,13 +8,7 @@ import type { RemoteRunOptions, RemoteRunResult } from './test.js';
|
|
|
9
8
|
*/
|
|
10
9
|
export declare function runLocalCommand(options: RunLocalOptions): Promise<boolean>;
|
|
11
10
|
/**
|
|
12
|
-
* Run fixtures remotely
|
|
13
|
-
* Migrated from test.ts — full remote execution functionality.
|
|
11
|
+
* Run fixtures remotely, routed through the Platform.
|
|
14
12
|
*/
|
|
15
13
|
export declare function runRemoteCommand(fixture: string | undefined, options: RemoteRunOptions): Promise<boolean>;
|
|
16
|
-
/**
|
|
17
|
-
* Observe run completion via WebSocket (primary path).
|
|
18
|
-
* Falls back to HTTP polling if the WS connection fails.
|
|
19
|
-
*/
|
|
20
|
-
export declare function observeCompletion(fixtureId: string, runId: string, observeUrl: string, token: string, client: OrchestratorClient, options: RemoteRunOptions): Promise<RemoteRunResult>;
|
|
21
14
|
//# sourceMappingURL=run.d.ts.map
|