@visulima/vis 1.0.0-alpha.15 → 1.0.0-alpha.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/CHANGELOG.md +64 -0
- package/LICENSE.md +44 -233
- package/dist/bin.js +1 -1
- package/dist/config/index.d.ts +200 -94
- package/dist/config/index.js +1 -1
- package/dist/packem_chunks/bin.js +271 -271
- package/dist/packem_chunks/config.js +18 -0
- package/dist/packem_chunks/fix.js +1 -1
- package/dist/packem_chunks/handler.js +1 -1
- package/dist/packem_chunks/handler10.js +1 -1
- package/dist/packem_chunks/handler11.js +1 -1
- package/dist/packem_chunks/handler12.js +1 -1
- package/dist/packem_chunks/handler13.js +1 -1
- package/dist/packem_chunks/handler14.js +4 -4
- package/dist/packem_chunks/handler15.js +1 -1
- package/dist/packem_chunks/handler16.js +1 -1
- package/dist/packem_chunks/handler17.js +1 -1
- package/dist/packem_chunks/handler18.js +1 -1
- package/dist/packem_chunks/handler19.js +5 -5
- package/dist/packem_chunks/handler2.js +1 -1
- package/dist/packem_chunks/handler20.js +2 -1
- package/dist/packem_chunks/handler21.js +18 -1
- package/dist/packem_chunks/handler22.js +1 -5
- package/dist/packem_chunks/handler23.js +1 -1
- package/dist/packem_chunks/handler24.js +5 -3
- package/dist/packem_chunks/handler25.js +1 -1
- package/dist/packem_chunks/handler26.js +3 -1
- package/dist/packem_chunks/handler27.js +1 -7
- package/dist/packem_chunks/handler28.js +1 -23
- package/dist/packem_chunks/handler29.js +7 -3
- package/dist/packem_chunks/handler3.js +1 -1
- package/dist/packem_chunks/handler30.js +23 -18
- package/dist/packem_chunks/handler31.js +3 -1
- package/dist/packem_chunks/handler32.js +1 -2
- package/dist/packem_chunks/handler33.js +2 -25
- package/dist/packem_chunks/handler34.js +25 -2
- package/dist/packem_chunks/handler35.js +2 -2
- package/dist/packem_chunks/handler36.js +8 -8
- package/dist/packem_chunks/handler37.js +3 -3
- package/dist/packem_chunks/handler38.js +3 -3
- package/dist/packem_chunks/handler39.js +1 -1
- package/dist/packem_chunks/handler40.js +5 -5
- package/dist/packem_chunks/handler41.js +9 -9
- package/dist/packem_chunks/handler42.js +9 -9
- package/dist/packem_chunks/handler43.js +1 -1
- package/dist/packem_chunks/handler44.js +5 -5
- package/dist/packem_chunks/handler45.js +3 -3
- package/dist/packem_chunks/handler46.js +9 -9
- package/dist/packem_chunks/handler47.js +161 -36
- package/dist/packem_chunks/handler48.js +1 -1
- package/dist/packem_chunks/handler5.js +5 -5
- package/dist/packem_chunks/handler6.js +1 -1
- package/dist/packem_chunks/handler7.js +1 -1
- package/dist/packem_chunks/handler8.js +1 -1
- package/dist/packem_chunks/handler9.js +1 -1
- package/dist/packem_chunks/heal-accept.js +2 -2
- package/dist/packem_chunks/heal.js +1 -1
- package/dist/packem_chunks/help-command.js +16 -16
- package/dist/packem_chunks/index.js +1 -1
- package/dist/packem_chunks/loader.js +1 -1
- package/dist/packem_shared/{ai-analysis-CGVjqwdc.js → ai-analysis-C_GpXikx.js} +3 -3
- package/dist/packem_shared/ai-cache-DrCLD4gc.js +1 -0
- package/dist/packem_shared/ai-fix-CWOz12Om.js +43 -0
- package/dist/packem_shared/applyDefaults-DLY94gWA.js +1 -0
- package/dist/packem_shared/cache-directory-C_U1qsIw.js +1 -0
- package/dist/packem_shared/definePlugin-CWm4Dv_t.js +1 -0
- package/dist/packem_shared/dependency-scan-YdgNVvoz.js +2 -0
- package/dist/packem_shared/docker-B4i5yxtP.js +60 -0
- package/dist/packem_shared/failure-log-CSC6KfcO.js +2 -0
- package/dist/packem_shared/flakiness-Dzz-I3dB.js +1 -0
- package/dist/packem_shared/lifecycle-C7vfQmA3.js +2 -0
- package/dist/packem_shared/{lockfile-B7JJzxnL.js → lockfile-i-qvq_k8.js} +1 -1
- package/dist/packem_shared/otelPlugin-CJR2T_lk.js +1 -0
- package/dist/packem_shared/{readTomlSync-1fKo0R52-DAKNI1Me.js → readTomlSync-1fKo0R52-DtxWULlF.js} +1 -1
- package/dist/packem_shared/run-summary-utils-CJv75pla.js +1 -0
- package/dist/packem_shared/runtime-check-CBU6W8qG.js +1 -0
- package/dist/packem_shared/{selectors-Sem2CTYA.js → selectors-B2ISH581.js} +1 -1
- package/dist/packem_shared/toolchain-B7dckBQ1.js +5 -0
- package/dist/packem_shared/typosquats-B3A38-qx.js +1 -0
- package/dist/packem_shared/verify-WDStBFvK.js +1 -0
- package/dist/packem_shared/vis-update-app-D0uL3eO5.js +1 -0
- package/package.json +13 -13
- package/schemas/project.schema.json +12 -2
- package/schemas/vis-config.schema.json +248 -3
- package/dist/packem_chunks/applyDefaults.js +0 -2
- package/dist/packem_shared/ai-cache-BdPgSfg2.js +0 -1
- package/dist/packem_shared/ai-fix-iHtGLkJS.js +0 -43
- package/dist/packem_shared/cache-directory-DTfMSzT9.js +0 -1
- package/dist/packem_shared/dependency-scan-SQeRzrpJ.js +0 -2
- package/dist/packem_shared/docker-D5p9mRPU.js +0 -2
- package/dist/packem_shared/failure-log-CElcbnb9.js +0 -2
- package/dist/packem_shared/flakiness-C4t4_NoA.js +0 -1
- package/dist/packem_shared/otel-CO8UEfTa.js +0 -17
- package/dist/packem_shared/otelPlugin-DTynZDWh.js +0 -1
- package/dist/packem_shared/registry-D04iOQ5H.js +0 -2
- package/dist/packem_shared/run-summary-utils-BPraMTcm.js +0 -1
- package/dist/packem_shared/runtime-check-l4qFpo08.js +0 -1
- package/dist/packem_shared/toolchain-BhZNts--.js +0 -5
- package/dist/packem_shared/typosquats-Dr7VIL2B.js +0 -1
- package/dist/packem_shared/verify-C6NNOhTA.js +0 -1
- package/dist/packem_shared/vis-update-app-DGiMc5kb.js +0 -1
package/dist/config/index.d.ts
CHANGED
|
@@ -1,88 +1,7 @@
|
|
|
1
|
-
import { TaskResult, Task,
|
|
1
|
+
import { TargetConfiguration, TaskResult, Task, FingerprintContributor, ConstraintsConfig, NamedInputs, TaskRunnerOptions } from '@visulima/task-runner';
|
|
2
|
+
export { type FingerprintContributor } from '@visulima/task-runner';
|
|
2
3
|
import { Hookable } from 'hookable';
|
|
3
4
|
/**
|
|
4
|
-
* Typed hook surface exposed to vis plugins.
|
|
5
|
-
*
|
|
6
|
-
* Plugins subscribe via `hooks.hook(name, handler)` — handlers are
|
|
7
|
-
* awaited sequentially in registration order. Returning a promise
|
|
8
|
-
* delays the next hook firing until it resolves, so plugins can
|
|
9
|
-
* safely perform async setup/teardown.
|
|
10
|
-
*
|
|
11
|
-
* Naming deliberately mirrors vite-task / webpack-style verbs:
|
|
12
|
-
* before/after for boundaries, on<Event> for passive observation.
|
|
13
|
-
*/
|
|
14
|
-
interface VisHooks {
|
|
15
|
-
/**
|
|
16
|
-
* Fired after the entire task graph completes (including any
|
|
17
|
-
* failures). `results` maps task ID → {@link TaskResult}.
|
|
18
|
-
*/
|
|
19
|
-
"run:after": (results: Map<string, TaskResult>) => Promise<void> | void;
|
|
20
|
-
/**
|
|
21
|
-
* Fired once before any task in the graph starts, after workspace
|
|
22
|
-
* discovery and graph construction. Throwing aborts the run.
|
|
23
|
-
*/
|
|
24
|
-
"run:before": (context: {
|
|
25
|
-
tasks: Task[];
|
|
26
|
-
workspaceRoot: string;
|
|
27
|
-
}) => Promise<void> | void;
|
|
28
|
-
/**
|
|
29
|
-
* Fired after a task completes (success, failure, or cache hit).
|
|
30
|
-
* Receives the final {@link TaskResult}.
|
|
31
|
-
*/
|
|
32
|
-
"task:after": (task: Task, result: TaskResult) => Promise<void> | void;
|
|
33
|
-
/**
|
|
34
|
-
* Fired before each task begins execution — after scheduling, before
|
|
35
|
-
* the executor runs the command. Throwing aborts that single task.
|
|
36
|
-
*/
|
|
37
|
-
"task:before": (task: Task) => Promise<void> | void;
|
|
38
|
-
/** Fired when a task hit the local or remote cache. */
|
|
39
|
-
"task:cacheHit": (task: Task, result: TaskResult) => Promise<void> | void;
|
|
40
|
-
/**
|
|
41
|
-
* Fired when auto-fingerprint cache diagnostics reports a miss,
|
|
42
|
-
* carrying the human-readable reason string.
|
|
43
|
-
*/
|
|
44
|
-
"task:cacheMiss": (task: Task, reasons: string) => Promise<void> | void;
|
|
45
|
-
/** Fired when a task exits non-zero. */
|
|
46
|
-
"task:failure": (task: Task, result: TaskResult) => Promise<void> | void;
|
|
47
|
-
/**
|
|
48
|
-
* Fired with a stderr chunk as a running task emits it. Plugins
|
|
49
|
-
* that ship logs live (Slack, Datadog) should prefer this over
|
|
50
|
-
* `task:after` so they don't wait for the full buffer.
|
|
51
|
-
*/
|
|
52
|
-
"task:stderr": (task: Task, chunk: string) => Promise<void> | void;
|
|
53
|
-
/**
|
|
54
|
-
* Fired with a stdout chunk as a running task emits it. See
|
|
55
|
-
* `task:stderr` for semantics.
|
|
56
|
-
*/
|
|
57
|
-
"task:stdout": (task: Task, chunk: string) => Promise<void> | void;
|
|
58
|
-
}
|
|
59
|
-
/**
|
|
60
|
-
* Public plugin contract. Implementations register handlers by
|
|
61
|
-
* returning a partial {@link VisHooks} map from `hooks`, or by
|
|
62
|
-
* mutating the Hookable instance directly via `setup(hooks)` for
|
|
63
|
-
* advanced cases (dynamic registration, removeHook, etc.).
|
|
64
|
-
*
|
|
65
|
-
* Plugins are loaded in the order they appear in `visConfig.plugins`.
|
|
66
|
-
* Handler execution order within a hook follows registration order,
|
|
67
|
-
* so earlier plugins see events first.
|
|
68
|
-
*/
|
|
69
|
-
interface VisPlugin {
|
|
70
|
-
/**
|
|
71
|
-
* Declarative handlers — the common shape. One entry per hook
|
|
72
|
-
* name; pass a function or an array of functions (all run serially
|
|
73
|
-
* in order).
|
|
74
|
-
*/
|
|
75
|
-
hooks?: Partial<{ [K in keyof VisHooks]: VisHooks[K] | VisHooks[K][] }>;
|
|
76
|
-
/** Plugin name — surfaced in debug logs. */
|
|
77
|
-
name: string;
|
|
78
|
-
/**
|
|
79
|
-
* Imperative setup — receives the shared Hookable instance so the
|
|
80
|
-
* plugin can register hooks conditionally, unregister later, or
|
|
81
|
-
* use advanced APIs like `hookOnce`/`beforeEach`/`afterEach`.
|
|
82
|
-
*/
|
|
83
|
-
setup?: (hooks: Hookable<VisHooks>) => Promise<void> | void;
|
|
84
|
-
}
|
|
85
|
-
/**
|
|
86
5
|
* One family of upstream-coupled packages.
|
|
87
6
|
*
|
|
88
7
|
* `members` is an exact-match list. `prefixes` accept any dep whose
|
|
@@ -191,6 +110,40 @@ interface ServiceConfig {
|
|
|
191
110
|
};
|
|
192
111
|
}
|
|
193
112
|
/**
|
|
113
|
+
* Persisted registry entry. One JSON file per running service in
|
|
114
|
+
* `~/.vis-services/<workspaceHash>/<slug>.json`.
|
|
115
|
+
*/
|
|
116
|
+
interface ServiceEntry {
|
|
117
|
+
/** Resolved command actually spawned. Used for stale-PID detection. */
|
|
118
|
+
command: string;
|
|
119
|
+
/** Service config captured at start time. */
|
|
120
|
+
config: ServiceConfig;
|
|
121
|
+
cwd: string;
|
|
122
|
+
/**
|
|
123
|
+
* Env vars to forward to dependents. Resolved at start time —
|
|
124
|
+
* defaults to `config.env`, but a future `--env-from` flag could
|
|
125
|
+
* extend this without touching the registry consumer.
|
|
126
|
+
*/
|
|
127
|
+
env: Record<string, string>;
|
|
128
|
+
/** Target id, e.g. `apps/api:db`. */
|
|
129
|
+
id: string;
|
|
130
|
+
/** Absolute path to the captured stdout/stderr log file. */
|
|
131
|
+
logFile: string;
|
|
132
|
+
pid: number;
|
|
133
|
+
/**
|
|
134
|
+
* Filesystem-safe slug of `id`. `apps/api:db` → `apps_api__db`.
|
|
135
|
+
* Used as the entry's filename so registry reads can map slug → entry.
|
|
136
|
+
*/
|
|
137
|
+
slug: string;
|
|
138
|
+
/** ISO 8601 timestamp of when the service was started. */
|
|
139
|
+
startedAt: string;
|
|
140
|
+
/**
|
|
141
|
+
* vis version that started this service. Auto-attach refuses entries
|
|
142
|
+
* from a mismatched version — protects against schema drift.
|
|
143
|
+
*/
|
|
144
|
+
visVersion: string;
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
194
147
|
* Semantic classification for a target.
|
|
195
148
|
* - `build`: Generates one or more artifacts; cached by default.
|
|
196
149
|
* - `test`: Validation task (lint, typecheck, unit test). Default type.
|
|
@@ -437,6 +390,132 @@ interface VisTargetConfiguration extends Omit<TargetConfiguration, "options"> {
|
|
|
437
390
|
*/
|
|
438
391
|
type?: TargetType;
|
|
439
392
|
}
|
|
393
|
+
/**
|
|
394
|
+
* Typed hook surface exposed to vis plugins.
|
|
395
|
+
*
|
|
396
|
+
* Plugins subscribe via `hooks.hook(name, handler)` — handlers are
|
|
397
|
+
* awaited sequentially in registration order. Returning a promise
|
|
398
|
+
* delays the next hook firing until it resolves, so plugins can
|
|
399
|
+
* safely perform async setup/teardown.
|
|
400
|
+
*
|
|
401
|
+
* Naming deliberately mirrors vite-task / webpack-style verbs:
|
|
402
|
+
* before/after for boundaries, on<Event> for passive observation.
|
|
403
|
+
*/
|
|
404
|
+
interface VisHooks {
|
|
405
|
+
/**
|
|
406
|
+
* Fired after the entire task graph completes (including any
|
|
407
|
+
* failures). `results` maps task ID → {@link TaskResult}.
|
|
408
|
+
*/
|
|
409
|
+
"run:after": (results: Map<string, TaskResult>) => Promise<void> | void;
|
|
410
|
+
/**
|
|
411
|
+
* Fired once before any task in the graph starts, after workspace
|
|
412
|
+
* discovery and graph construction. Throwing aborts the run.
|
|
413
|
+
*/
|
|
414
|
+
"run:before": (context: {
|
|
415
|
+
tasks: Task[];
|
|
416
|
+
workspaceRoot: string;
|
|
417
|
+
}) => Promise<void> | void;
|
|
418
|
+
/**
|
|
419
|
+
* Fired after a task completes (success, failure, or cache hit).
|
|
420
|
+
* Receives the final {@link TaskResult}.
|
|
421
|
+
*/
|
|
422
|
+
"task:after": (task: Task, result: TaskResult) => Promise<void> | void;
|
|
423
|
+
/**
|
|
424
|
+
* Fired before each task begins execution — after scheduling, before
|
|
425
|
+
* the executor runs the command. Throwing aborts that single task.
|
|
426
|
+
*/
|
|
427
|
+
"task:before": (task: Task) => Promise<void> | void;
|
|
428
|
+
/** Fired when a task hit the local or remote cache. */
|
|
429
|
+
"task:cacheHit": (task: Task, result: TaskResult) => Promise<void> | void;
|
|
430
|
+
/**
|
|
431
|
+
* Fired when auto-fingerprint cache diagnostics reports a miss,
|
|
432
|
+
* carrying the human-readable reason string.
|
|
433
|
+
*/
|
|
434
|
+
"task:cacheMiss": (task: Task, reasons: string) => Promise<void> | void;
|
|
435
|
+
/** Fired when a task exits non-zero. */
|
|
436
|
+
"task:failure": (task: Task, result: TaskResult) => Promise<void> | void;
|
|
437
|
+
/**
|
|
438
|
+
* Fired with a stderr chunk as a running task emits it. Plugins
|
|
439
|
+
* that ship logs live (Slack, Datadog) should prefer this over
|
|
440
|
+
* `task:after` so they don't wait for the full buffer.
|
|
441
|
+
*/
|
|
442
|
+
"task:stderr": (task: Task, chunk: string) => Promise<void> | void;
|
|
443
|
+
/**
|
|
444
|
+
* Fired with a stdout chunk as a running task emits it. See
|
|
445
|
+
* `task:stderr` for semantics.
|
|
446
|
+
*/
|
|
447
|
+
"task:stdout": (task: Task, chunk: string) => Promise<void> | void;
|
|
448
|
+
/**
|
|
449
|
+
* Fired during fingerprint construction, after built-in inputs are
|
|
450
|
+
* gathered and before the hash is sealed. Plugins call
|
|
451
|
+
* `contributor.contribute(key, value)` to mix arbitrary strings
|
|
452
|
+
* into the task hash — the hasher namespaces and sorts contributions
|
|
453
|
+
* deterministically so call order doesn't change the result.
|
|
454
|
+
*
|
|
455
|
+
* Throwing aborts hashing for the offending task and surfaces as a
|
|
456
|
+
* task failure before any cache lookup runs. Use this to guarantee
|
|
457
|
+
* a buggy plugin can't quietly poison cache state.
|
|
458
|
+
*/
|
|
459
|
+
"task:fingerprint": (task: Task, contributor: FingerprintContributor) => Promise<void> | void;
|
|
460
|
+
/**
|
|
461
|
+
* Fired right before a failed task is re-spawned by the retry
|
|
462
|
+
* controller. `attempt` is 1-indexed and counts the retry that's
|
|
463
|
+
* about to start (so the original failed run was attempt 0).
|
|
464
|
+
* `prevExitCode` is the failing exit status that triggered the
|
|
465
|
+
* retry (the full TaskResult isn't materialized at the retry
|
|
466
|
+
* boundary — only the per-attempt close event is available).
|
|
467
|
+
*
|
|
468
|
+
* Throwing aborts the retry; the previous failure becomes the final
|
|
469
|
+
* result.
|
|
470
|
+
*/
|
|
471
|
+
"task:retry": (task: Task, attempt: number, prevExitCode: number) => Promise<void> | void;
|
|
472
|
+
/**
|
|
473
|
+
* Fired after `vis run` auto-attaches to one or more registered
|
|
474
|
+
* services. `taskIds` lists the in-graph dependents that consumed
|
|
475
|
+
* the service's `env` block; an empty array means the service was
|
|
476
|
+
* registered but no kept task depended on it.
|
|
477
|
+
*/
|
|
478
|
+
"service:attach": (entry: ServiceEntry, taskIds: ReadonlyArray<string>) => Promise<void> | void;
|
|
479
|
+
/**
|
|
480
|
+
* Fired after a service is registered and its readiness probe
|
|
481
|
+
* succeeds. Sourced from both `vis service start` (and `restart`'s
|
|
482
|
+
* post-start phase) and any future programmatic call sites.
|
|
483
|
+
*/
|
|
484
|
+
"service:start": (entry: ServiceEntry) => Promise<void> | void;
|
|
485
|
+
/**
|
|
486
|
+
* Fired after a registered service is stopped (SIGTERM/SIGKILL
|
|
487
|
+
* acknowledged, registry entry deleted). Not fired when stop is
|
|
488
|
+
* called against an unknown id — only when there was an alive
|
|
489
|
+
* entry to terminate.
|
|
490
|
+
*/
|
|
491
|
+
"service:stop": (entry: ServiceEntry) => Promise<void> | void;
|
|
492
|
+
}
|
|
493
|
+
/**
|
|
494
|
+
* Public plugin contract. Implementations register handlers by
|
|
495
|
+
* returning a partial {@link VisHooks} map from `hooks`, or by
|
|
496
|
+
* mutating the Hookable instance directly via `setup(hooks)` for
|
|
497
|
+
* advanced cases (dynamic registration, removeHook, etc.).
|
|
498
|
+
*
|
|
499
|
+
* Plugins are loaded in the order they appear in `visConfig.plugins`.
|
|
500
|
+
* Handler execution order within a hook follows registration order,
|
|
501
|
+
* so earlier plugins see events first.
|
|
502
|
+
*/
|
|
503
|
+
interface VisPlugin {
|
|
504
|
+
/**
|
|
505
|
+
* Declarative handlers — the common shape. One entry per hook
|
|
506
|
+
* name; pass a function or an array of functions (all run serially
|
|
507
|
+
* in order).
|
|
508
|
+
*/
|
|
509
|
+
hooks?: Partial<{ [K in keyof VisHooks]: VisHooks[K] | VisHooks[K][] }>;
|
|
510
|
+
/** Plugin name — surfaced in debug logs. */
|
|
511
|
+
name: string;
|
|
512
|
+
/**
|
|
513
|
+
* Imperative setup — receives the shared Hookable instance so the
|
|
514
|
+
* plugin can register hooks conditionally, unregister later, or
|
|
515
|
+
* use advanced APIs like `hookOnce`/`beforeEach`/`afterEach`.
|
|
516
|
+
*/
|
|
517
|
+
setup?: (hooks: Hookable<VisHooks>) => Promise<void> | void;
|
|
518
|
+
}
|
|
440
519
|
interface CodeownersConfig {
|
|
441
520
|
/** Workspace-level paths that apply outside any project (e.g., `.github/**`). */
|
|
442
521
|
globalPaths?: Record<string, string[]>;
|
|
@@ -521,8 +600,15 @@ interface ProjectJson {
|
|
|
521
600
|
owner?: string;
|
|
522
601
|
title?: string;
|
|
523
602
|
};
|
|
524
|
-
/**
|
|
525
|
-
|
|
603
|
+
/**
|
|
604
|
+
* Project type — `library`, `application`, `service`, or `tool`.
|
|
605
|
+
*
|
|
606
|
+
* - `library` — reusable code consumed by other workspace projects.
|
|
607
|
+
* - `application` — end-user-facing build target (web app, mobile app).
|
|
608
|
+
* - `service` — long-running HTTP / worker process deployed independently.
|
|
609
|
+
* - `tool` — CLI or developer tooling shipped as an executable.
|
|
610
|
+
*/
|
|
611
|
+
projectType?: "application" | "library" | "service" | "tool";
|
|
526
612
|
/** Source root, used for display and language inference. */
|
|
527
613
|
sourceRoot?: string;
|
|
528
614
|
/** Tech stack. */
|
|
@@ -542,7 +628,7 @@ interface TaskDefaultsScope {
|
|
|
542
628
|
/** Match on project layer. */
|
|
543
629
|
layer?: ProjectJson["layer"] | ProjectJson["layer"][];
|
|
544
630
|
/** Match on project type. */
|
|
545
|
-
projectType?: "application" | "library";
|
|
631
|
+
projectType?: "application" | "library" | "service" | "tool";
|
|
546
632
|
/** Match on project stack. */
|
|
547
633
|
stack?: ProjectJson["stack"] | ProjectJson["stack"][];
|
|
548
634
|
/** Match projects tagged with any of these tags. */
|
|
@@ -1147,6 +1233,22 @@ interface VisConfig {
|
|
|
1147
1233
|
lockfile?: boolean;
|
|
1148
1234
|
};
|
|
1149
1235
|
/**
|
|
1236
|
+
* Behavior of `vis run` when invoked tasks declare service dependencies
|
|
1237
|
+
* that aren't running in the workspace registry. CLI `--services=<mode>`
|
|
1238
|
+
* overrides this block.
|
|
1239
|
+
*/
|
|
1240
|
+
run?: {
|
|
1241
|
+
/**
|
|
1242
|
+
* One knob controlling auto-start of missing service deps.
|
|
1243
|
+
* - `auto` (default in TTY): pick by task — `dev` → ephemeral,
|
|
1244
|
+
* others → persistent.
|
|
1245
|
+
* - `ephemeral`: services die with the run (no registry entry).
|
|
1246
|
+
* - `persistent`: services persist across runs in the registry.
|
|
1247
|
+
* - `off` (default in CI / non-TTY): print diagnostics and abort.
|
|
1248
|
+
*/
|
|
1249
|
+
services?: "auto" | "ephemeral" | "off" | "persistent";
|
|
1250
|
+
};
|
|
1251
|
+
/**
|
|
1150
1252
|
* Default options for `vis secrets`. CLI flags always take precedence;
|
|
1151
1253
|
* this block provides workspace-wide defaults so teams can commit config
|
|
1152
1254
|
* once and every invocation picks it up.
|
|
@@ -1349,8 +1451,8 @@ interface VisConfig {
|
|
|
1349
1451
|
/**
|
|
1350
1452
|
* Share the cache between sibling git worktrees. When the workspace is a
|
|
1351
1453
|
* linked worktree (created with `git worktree add`), the cache root is
|
|
1352
|
-
* relocated from `<linkedRoot>/.
|
|
1353
|
-
* worktree's `.
|
|
1454
|
+
* relocated from `<linkedRoot>/.vis/cache` to the *main*
|
|
1455
|
+
* worktree's `.vis/cache`. Multiple parallel agents working in
|
|
1354
1456
|
* sibling worktrees then share a single cache instead of rebuilding the
|
|
1355
1457
|
* same hash N times.
|
|
1356
1458
|
*
|
|
@@ -2098,6 +2200,16 @@ interface OtelPluginOptions {
|
|
|
2098
2200
|
* ```
|
|
2099
2201
|
*/
|
|
2100
2202
|
declare const otelPlugin: (options: OtelPluginOptions) => VisPlugin;
|
|
2203
|
+
/**
|
|
2204
|
+
* Type-safe helper for defining a vis plugin. Pure identity — exists
|
|
2205
|
+
* only so plugin authors get inference from the `VisPlugin` contract
|
|
2206
|
+
* without needing a `satisfies` annotation.
|
|
2207
|
+
*
|
|
2208
|
+
* Lives in its own module so plugins can import it without going
|
|
2209
|
+
* through `config.ts`, which re-exports plugins like `otelPlugin` and
|
|
2210
|
+
* would otherwise form an import cycle.
|
|
2211
|
+
*/
|
|
2212
|
+
declare const definePlugin: (plugin: VisPlugin) => VisPlugin;
|
|
2101
2213
|
/** Supported config file names, checked in priority order. */
|
|
2102
2214
|
declare const CONFIG_FILES: string[];
|
|
2103
2215
|
/** Per-package overlay file names, checked in priority order. */
|
|
@@ -2222,10 +2334,4 @@ declare const defineTaskConfig: (config: VisTaskConfig) => VisTaskConfig;
|
|
|
2222
2334
|
* ```
|
|
2223
2335
|
*/
|
|
2224
2336
|
declare const defineConfig: (config: VisConfig) => VisConfig;
|
|
2225
|
-
/**
|
|
2226
|
-
* Type-safe helper for defining a vis plugin. Pure identity — exists
|
|
2227
|
-
* only so plugin authors get inference from the `VisPlugin` contract
|
|
2228
|
-
* without needing a `satisfies` annotation.
|
|
2229
|
-
*/
|
|
2230
|
-
declare const definePlugin: (plugin: VisPlugin) => VisPlugin;
|
|
2231
2337
|
export { CONFIG_FILES, type OtelPluginOptions, SECURITY_DEFAULTS, TASK_CONFIG_FILES, type VisConfig, type VisHooks, type VisPlugin, type VisTaskConfig, applyDefaults, defineConfig, definePlugin, defineTaskConfig, findVisConfigFile, findVisTaskConfigFile, loadVisConfig, loadVisTaskConfig, otelPlugin };
|
package/dist/config/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{p as a,O as f,k as o,l as e,r as n,i as l,j as C,I as g,X as d,e as r}from"../packem_chunks/config.js";import{definePlugin as p}from"../packem_shared/definePlugin-CWm4Dv_t.js";import{otelPlugin as T}from"../packem_shared/otelPlugin-CJR2T_lk.js";export{a as CONFIG_FILES,f as SECURITY_DEFAULTS,o as TASK_CONFIG_FILES,e as applyDefaults,n as defineConfig,p as definePlugin,l as defineTaskConfig,C as findVisConfigFile,g as findVisTaskConfigFile,d as loadVisConfig,r as loadVisTaskConfig,T as otelPlugin};
|