@mark1russell7/stack-setup 0.0.0-stage → 0.1.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.
@@ -0,0 +1,151 @@
1
+ /** The name of the format of a setup layer. It is the key of the layer in `Stack.layers`. */
2
+ declare const SETUP_SCHEMA = "setup/1";
3
+ /** A value that the script reads from its environment at its start, for example a key. No record holds its value. */
4
+ interface VariableRead {
5
+ /** The name of a variable of the layer. */
6
+ readonly $var: string;
7
+ }
8
+ /**
9
+ * A text of a step.
10
+ *
11
+ * - A string is literal. The script quotes it, so the shell expands nothing in it.
12
+ * - `{ "$var": "NAME" }` is the value of a variable of the layer, from the environment when the script runs.
13
+ * - A list joins its parts into one text, for example `["token=", { "$var": "TOKEN" }, "\n"]`.
14
+ */
15
+ type SetupText = string | VariableRead | readonly (string | VariableRead)[];
16
+ /** A variable of the layer. A person or a program gives its value in the environment of the script. A variable has no default. */
17
+ interface Variable {
18
+ /** The name: capital letters, digits and `_`, with a letter first. The script itself uses only lowercase names. */
19
+ readonly name: string;
20
+ /** `true`: the value is a secret. The gate refuses it in a file that each user can read, and in a unit of a service. */
21
+ readonly sensitive?: boolean | undefined;
22
+ readonly description?: string | undefined;
23
+ }
24
+ /** The fields of each step. */
25
+ interface StepBase {
26
+ /** The name of the step in its profile. The address of a step is the name of the profile, a point and this name. */
27
+ readonly id: string;
28
+ readonly description?: string | undefined;
29
+ }
30
+ /** Packages of the system package manager. The step installs each package that is not installed. */
31
+ interface PackageStep extends StepBase {
32
+ readonly kind: "package";
33
+ /** The package manager. Only `apt` is known. */
34
+ readonly manager: "apt";
35
+ /** The names of the packages. */
36
+ readonly names: readonly string[];
37
+ }
38
+ /** A user account of the host. */
39
+ interface UserStep extends StepBase {
40
+ readonly kind: "user";
41
+ /** The login name. */
42
+ readonly name: string;
43
+ /** The extra groups of the user. Each group exists before the step. The step adds the user to each group, and removes none. */
44
+ readonly groups?: readonly string[] | undefined;
45
+ /** The login shell. The default is `/bin/bash`. */
46
+ readonly shell?: string | undefined;
47
+ /**
48
+ * The public SSH keys, each one a line of `authorized_keys`. The step writes the file with these keys only.
49
+ * With no field, the step does not change the file.
50
+ */
51
+ readonly keys?: readonly string[] | undefined;
52
+ }
53
+ /** A file with a text. The step writes the file when its text, its mode or its owner is different. */
54
+ interface FileStep extends StepBase {
55
+ readonly kind: "file";
56
+ /** The absolute path. */
57
+ readonly path: string;
58
+ /** The text of the file. */
59
+ readonly text: SetupText;
60
+ /** The mode in octal, for example `644`. The default is `644`. */
61
+ readonly mode?: string | undefined;
62
+ /** The user that owns the file. The default is `root`. */
63
+ readonly owner?: string | undefined;
64
+ /** The group that owns the file. The default is `root`. */
65
+ readonly group?: string | undefined;
66
+ }
67
+ /** A file from an HTTPS address, with its checksum. The step keeps a file only when its SHA-256 agrees. */
68
+ interface DownloadStep extends StepBase {
69
+ readonly kind: "download";
70
+ /** The HTTPS address of the file. */
71
+ readonly url: string;
72
+ /** The SHA-256 of the file, as 64 lowercase hexadecimal digits. */
73
+ readonly sha256: string;
74
+ /** The absolute path. */
75
+ readonly path: string;
76
+ /** The mode in octal. The default is `644`. */
77
+ readonly mode?: string | undefined;
78
+ }
79
+ /** A swap file. The step makes the file, turns it on and adds it to `/etc/fstab`. */
80
+ interface SwapStep extends StepBase {
81
+ readonly kind: "swap";
82
+ /** The absolute path. */
83
+ readonly path: string;
84
+ /** The size in MiB, from 1 to 65536. */
85
+ readonly mib: number;
86
+ }
87
+ /** A service of systemd. The step writes its unit, and starts the service at each boot. */
88
+ interface ServiceStep extends StepBase {
89
+ readonly kind: "service";
90
+ /** The name of the unit with no `.service`, for example `example-runtime`. */
91
+ readonly name: string;
92
+ /** The text of the unit file. Each user can read a unit, so it reads no secret. */
93
+ readonly unit: SetupText;
94
+ /** `false`: the step writes the unit only. The default is `true`: the service starts with the script and at each boot. */
95
+ readonly enable?: boolean | undefined;
96
+ }
97
+ /**
98
+ * A command with its check. The step starts `run` only when `check` fails, and then `check` must pass.
99
+ * Each command is a list of arguments, with no shell. The first argument is a literal program.
100
+ */
101
+ interface CommandStep extends StepBase {
102
+ readonly kind: "command";
103
+ /** The command that makes the change. */
104
+ readonly run: readonly SetupText[];
105
+ /** The command that tells if the change is there: exit code 0 tells that it is. */
106
+ readonly check: readonly SetupText[];
107
+ /** The user of the two commands. The default is `root`. */
108
+ readonly as?: string | undefined;
109
+ }
110
+ /** A step of the setup. */
111
+ type Step = PackageStep | UserStep | FileStep | DownloadStep | SwapStep | ServiceStep | CommandStep;
112
+ /** The kinds of a step. */
113
+ declare const STEP_KINDS: readonly ["package", "user", "file", "download", "swap", "service", "command"];
114
+ /** A kind of a step. */
115
+ type StepKind = Step["kind"];
116
+ /**
117
+ * The setup of one part of the stack on its hosts, as steps in order.
118
+ * The setup of a host has the steps of each profile of the host. A profile comes after each profile whose part its part needs.
119
+ */
120
+ interface Profile {
121
+ /** The name of the profile. */
122
+ readonly name: string;
123
+ /** The `id` of the part of the stack that the steps set up, for example a runtime. */
124
+ readonly part: string;
125
+ /** The `id` of each host part that runs the steps. A host can be the part itself. */
126
+ readonly hosts: readonly string[];
127
+ /** The steps, in order. */
128
+ readonly steps: readonly Step[];
129
+ }
130
+ /** The setup layer of a stack. */
131
+ interface SetupLayer {
132
+ readonly schema: typeof SETUP_SCHEMA;
133
+ readonly variables?: readonly Variable[] | undefined;
134
+ readonly profiles: readonly Profile[];
135
+ }
136
+ /** This function gives the address of a step: the name of its profile, a point and its `id`. */
137
+ declare function stepAddress(profile: Profile, step: Step): string;
138
+ /** This function tells if a value is a variable read: an object with a text field `$var` that is not a list. */
139
+ declare function isVariableRead(value: unknown): value is VariableRead;
140
+ /** This function gives the parts of a text: each string and each variable read, in order. */
141
+ declare function textParts(text: SetupText): readonly (string | VariableRead)[];
142
+ /** This function gives the names of the variables that a text reads, in order, with no repeat. */
143
+ declare function textVariables(text: SetupText): string[];
144
+ /** This function gives each text of a step, for a walk over its variables. */
145
+ declare function stepTexts(step: Step): readonly SetupText[];
146
+ /** This function gives the paths that a step writes. Two steps of one host cannot write one path. */
147
+ declare function stepPaths(step: Step): string[];
148
+ /** This function gives the path of the unit file of a service. */
149
+ declare function unitPath(name: string): string;
150
+ export { unitPath as C, textVariables as S, isVariableRead as _, Profile as a, stepTexts as b, ServiceStep as c, Step as d, StepKind as f, VariableRead as g, Variable as h, PackageStep as i, SetupLayer as l, UserStep as m, DownloadStep as n, SETUP_SCHEMA as o, SwapStep as p, FileStep as r, STEP_KINDS as s, CommandStep as t, SetupText as u, stepAddress as v, textParts as x, stepPaths as y };
151
+ //# sourceMappingURL=layer-Db50psxJ.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"layer-Db50psxJ.d.ts","names":[],"sources":["../src/layer.ts"],"mappings":";cAKa;;UAGI;;WAEN;;;;;;;;;KAUC,qBAAqB,kCAAkC;;UAGlD;;WAEN;;WAEA;WACA;;;UAID;;WAEC;WACA;;;UAIM,oBAAoB;WAC1B;;WAEA;;WAEA;;;UAIM,iBAAiB;WACvB;;WAEA;;WAEA;;WAEA;;;;;WAKA;;;UAIM,iBAAiB;WACvB;;WAEA;;WAEA,MAAM;;WAEN;;WAEA;;WAEA;;;UAIM,qBAAqB;WAC3B;;WAEA;;WAEA;;WAEA;;WAEA;;;UAIM,iBAAiB;WACvB;;WAEA;;WAEA;;;UAIM,oBAAoB;WAC1B;;WAEA;;WAEA,MAAM;;WAEN;;;;;;UAOM,oBAAoB;WAC1B;;WAEA,cAAc;;WAEd,gBAAgB;;WAEhB;;;KAIC,OAAO,cAAc,WAAW,WAAW,eAAe,WAAW,cAAc;;cAGlF;;KAGD,WAAW;;;;;UAMN;;WAEN;;WAEA;;WAEA;;WAEA,gBAAgB;;;UAIV;WACN,eAAe;WACf,qBAAqB;WACrB,mBAAmB;;;iBAId,YAAY,SAAS,SAAS,MAAM;;iBAKpC,eAAe,iBAAiB,SAAS;;iBAKzC,UAAU,MAAM,+BAA+B;;iBAM/C,cAAc,MAAM;;iBAOpB,UAAU,MAAM,gBAAgB;;iBAchC,UAAU,MAAM;;iBAchB,SAAS"}
@@ -0,0 +1,21 @@
1
+ import { l as SetupLayer } from "./layer-Db50psxJ.js";
2
+ import { z } from "zod";
3
+ /**
4
+ * The schema of a setup layer. It examines the form of the record: the fields and their types.
5
+ * It refuses a field that the format does not have. `checkSetup` examines the meaning of a layer with a correct form.
6
+ */
7
+ export declare const setupSchema: z.ZodType<SetupLayer>;
8
+ /** The result of the read of a setup layer: the layer, or the faults of its form. */
9
+ export type SetupParse = {
10
+ readonly ok: true;
11
+ readonly layer: SetupLayer;
12
+ } | {
13
+ readonly ok: false;
14
+ readonly errors: readonly string[];
15
+ };
16
+ /**
17
+ * This function reads the JSON of a setup layer. It gives the layer, or the faults of its form.
18
+ * Each fault names its place in the record, for example `profiles.0.steps.1.kind`.
19
+ */
20
+ export declare function parseSetup(input: unknown): SetupParse;
21
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","names":[],"sources":["../src/schema.ts"],"mappings":";;;;;;qBAiGa,aAAa,EAAE,QAAQ;;YAOxB;WAAwB;WAAmB,OAAO;;WAA0B;WAAoB;;;;;;wBAM5F,WAAW,iBAAiB"}
@@ -0,0 +1,117 @@
1
+ import { t as SETUP_SCHEMA } from "./layer-DWfBSz3H.js";
2
+ import { formErrors } from "@mark1russell7/system-stack/schema";
3
+ import { z } from "zod";
4
+ // src/schema.ts
5
+ const id = z.string().min(1);
6
+ const description = z.string().optional();
7
+ const variableRead = z.strictObject({ $var: id });
8
+ const text = z.union([
9
+ z.string(),
10
+ variableRead,
11
+ z.array(z.union([z.string(), variableRead])).readonly()
12
+ ]);
13
+ const variable = z.strictObject({
14
+ name: id,
15
+ sensitive: z.boolean().optional(),
16
+ description
17
+ });
18
+ const packageStep = z.strictObject({
19
+ kind: z.literal("package"),
20
+ id,
21
+ description,
22
+ manager: z.literal("apt"),
23
+ names: z.array(id).readonly()
24
+ });
25
+ const userStep = z.strictObject({
26
+ kind: z.literal("user"),
27
+ id,
28
+ description,
29
+ name: id,
30
+ groups: z.array(id).readonly().optional(),
31
+ shell: id.optional(),
32
+ keys: z.array(z.string()).readonly().optional()
33
+ });
34
+ const fileStep = z.strictObject({
35
+ kind: z.literal("file"),
36
+ id,
37
+ description,
38
+ path: id,
39
+ text,
40
+ mode: id.optional(),
41
+ owner: id.optional(),
42
+ group: id.optional()
43
+ });
44
+ const downloadStep = z.strictObject({
45
+ kind: z.literal("download"),
46
+ id,
47
+ description,
48
+ url: id,
49
+ sha256: id,
50
+ path: id,
51
+ mode: id.optional()
52
+ });
53
+ const swapStep = z.strictObject({
54
+ kind: z.literal("swap"),
55
+ id,
56
+ description,
57
+ path: id,
58
+ mib: z.number()
59
+ });
60
+ const serviceStep = z.strictObject({
61
+ kind: z.literal("service"),
62
+ id,
63
+ description,
64
+ name: id,
65
+ unit: text,
66
+ enable: z.boolean().optional()
67
+ });
68
+ const commandStep = z.strictObject({
69
+ kind: z.literal("command"),
70
+ id,
71
+ description,
72
+ run: z.array(text).readonly(),
73
+ check: z.array(text).readonly(),
74
+ as: id.optional()
75
+ });
76
+ const step = z.discriminatedUnion("kind", [
77
+ packageStep,
78
+ userStep,
79
+ fileStep,
80
+ downloadStep,
81
+ swapStep,
82
+ serviceStep,
83
+ commandStep
84
+ ]);
85
+ const profile = z.strictObject({
86
+ name: id,
87
+ part: id,
88
+ hosts: z.array(id).readonly(),
89
+ steps: z.array(step).readonly()
90
+ });
91
+ /**
92
+ * The schema of a setup layer. It examines the form of the record: the fields and their types.
93
+ * It refuses a field that the format does not have. `checkSetup` examines the meaning of a layer with a correct form.
94
+ */
95
+ const setupSchema = z.strictObject({
96
+ schema: z.literal(SETUP_SCHEMA),
97
+ variables: z.array(variable).readonly().optional(),
98
+ profiles: z.array(profile).readonly()
99
+ });
100
+ /**
101
+ * This function reads the JSON of a setup layer. It gives the layer, or the faults of its form.
102
+ * Each fault names its place in the record, for example `profiles.0.steps.1.kind`.
103
+ */
104
+ function parseSetup(input) {
105
+ const read = setupSchema.safeParse(input);
106
+ if (read.success) return {
107
+ ok: true,
108
+ layer: read.data
109
+ };
110
+ return {
111
+ ok: false,
112
+ errors: formErrors(SETUP_SCHEMA, read.error.issues)
113
+ };
114
+ }
115
+ export { parseSetup, setupSchema };
116
+
117
+ //# sourceMappingURL=schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","names":[],"sources":["../src/schema.ts"],"sourcesContent":["import { formErrors } from \"@mark1russell7/system-stack/schema\";\nimport { z } from \"zod\";\nimport { SETUP_SCHEMA, type SetupLayer } from \"./layer.ts\";\n\n// The zod schema of a setup layer and the read of its JSON. This module is the entry `/schema` of the package.\n// The root entry has no zod, so a host that only generates a script gets no schema library.\n\nconst id = z.string().min(1);\nconst description = z.string().optional();\n\nconst variableRead = z.strictObject({ $var: id });\nconst text = z.union([z.string(), variableRead, z.array(z.union([z.string(), variableRead])).readonly()]);\n\nconst variable = z.strictObject({\n name: id,\n sensitive: z.boolean().optional(),\n description,\n});\n\nconst packageStep = z.strictObject({\n kind: z.literal(\"package\"),\n id,\n description,\n manager: z.literal(\"apt\"),\n names: z.array(id).readonly(),\n});\n\nconst userStep = z.strictObject({\n kind: z.literal(\"user\"),\n id,\n description,\n name: id,\n groups: z.array(id).readonly().optional(),\n shell: id.optional(),\n keys: z.array(z.string()).readonly().optional(),\n});\n\nconst fileStep = z.strictObject({\n kind: z.literal(\"file\"),\n id,\n description,\n path: id,\n text,\n mode: id.optional(),\n owner: id.optional(),\n group: id.optional(),\n});\n\nconst downloadStep = z.strictObject({\n kind: z.literal(\"download\"),\n id,\n description,\n url: id,\n sha256: id,\n path: id,\n mode: id.optional(),\n});\n\nconst swapStep = z.strictObject({\n kind: z.literal(\"swap\"),\n id,\n description,\n path: id,\n mib: z.number(),\n});\n\nconst serviceStep = z.strictObject({\n kind: z.literal(\"service\"),\n id,\n description,\n name: id,\n unit: text,\n enable: z.boolean().optional(),\n});\n\nconst commandStep = z.strictObject({\n kind: z.literal(\"command\"),\n id,\n description,\n run: z.array(text).readonly(),\n check: z.array(text).readonly(),\n as: id.optional(),\n});\n\nconst step = z.discriminatedUnion(\"kind\", [packageStep, userStep, fileStep, downloadStep, swapStep, serviceStep, commandStep]);\n\nconst profile = z.strictObject({\n name: id,\n part: id,\n hosts: z.array(id).readonly(),\n steps: z.array(step).readonly(),\n});\n\n/**\n * The schema of a setup layer. It examines the form of the record: the fields and their types.\n * It refuses a field that the format does not have. `checkSetup` examines the meaning of a layer with a correct form.\n */\nexport const setupSchema: z.ZodType<SetupLayer> = z.strictObject({\n schema: z.literal(SETUP_SCHEMA),\n variables: z.array(variable).readonly().optional(),\n profiles: z.array(profile).readonly(),\n});\n\n/** The result of the read of a setup layer: the layer, or the faults of its form. */\nexport type SetupParse = { readonly ok: true; readonly layer: SetupLayer } | { readonly ok: false; readonly errors: readonly string[] };\n\n/**\n * This function reads the JSON of a setup layer. It gives the layer, or the faults of its form.\n * Each fault names its place in the record, for example `profiles.0.steps.1.kind`.\n */\nexport function parseSetup(input: unknown): SetupParse {\n const read = setupSchema.safeParse(input);\n if (read.success) return { ok: true, layer: read.data };\n return { ok: false, errors: formErrors(SETUP_SCHEMA, read.error.issues) };\n}\n"],"mappings":";;;;AAOA,MAAM,KAAK,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC;AAC3B,MAAM,cAAc,EAAE,OAAO,CAAC,CAAC,SAAS;AAExC,MAAM,eAAe,EAAE,aAAa,EAAE,MAAM,GAAG,CAAC;AAChD,MAAM,OAAO,EAAE,MAAM;CAAC,EAAE,OAAO;CAAG;CAAc,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,OAAO,GAAG,YAAY,CAAC,CAAC,CAAC,CAAC,SAAS;AAAC,CAAC;AAExG,MAAM,WAAW,EAAE,aAAa;CAC9B,MAAM;CACN,WAAW,EAAE,QAAQ,CAAC,CAAC,SAAS;CAChC;AACF,CAAC;AAED,MAAM,cAAc,EAAE,aAAa;CACjC,MAAM,EAAE,QAAQ,SAAS;CACzB;CACA;CACA,SAAS,EAAE,QAAQ,KAAK;CACxB,OAAO,EAAE,MAAM,EAAE,CAAC,CAAC,SAAS;AAC9B,CAAC;AAED,MAAM,WAAW,EAAE,aAAa;CAC9B,MAAM,EAAE,QAAQ,MAAM;CACtB;CACA;CACA,MAAM;CACN,QAAQ,EAAE,MAAM,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACxC,OAAO,GAAG,SAAS;CACnB,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AAChD,CAAC;AAED,MAAM,WAAW,EAAE,aAAa;CAC9B,MAAM,EAAE,QAAQ,MAAM;CACtB;CACA;CACA,MAAM;CACN;CACA,MAAM,GAAG,SAAS;CAClB,OAAO,GAAG,SAAS;CACnB,OAAO,GAAG,SAAS;AACrB,CAAC;AAED,MAAM,eAAe,EAAE,aAAa;CAClC,MAAM,EAAE,QAAQ,UAAU;CAC1B;CACA;CACA,KAAK;CACL,QAAQ;CACR,MAAM;CACN,MAAM,GAAG,SAAS;AACpB,CAAC;AAED,MAAM,WAAW,EAAE,aAAa;CAC9B,MAAM,EAAE,QAAQ,MAAM;CACtB;CACA;CACA,MAAM;CACN,KAAK,EAAE,OAAO;AAChB,CAAC;AAED,MAAM,cAAc,EAAE,aAAa;CACjC,MAAM,EAAE,QAAQ,SAAS;CACzB;CACA;CACA,MAAM;CACN,MAAM;CACN,QAAQ,EAAE,QAAQ,CAAC,CAAC,SAAS;AAC/B,CAAC;AAED,MAAM,cAAc,EAAE,aAAa;CACjC,MAAM,EAAE,QAAQ,SAAS;CACzB;CACA;CACA,KAAK,EAAE,MAAM,IAAI,CAAC,CAAC,SAAS;CAC5B,OAAO,EAAE,MAAM,IAAI,CAAC,CAAC,SAAS;CAC9B,IAAI,GAAG,SAAS;AAClB,CAAC;AAED,MAAM,OAAO,EAAE,mBAAmB,QAAQ;CAAC;CAAa;CAAU;CAAU;CAAc;CAAU;CAAa;AAAW,CAAC;AAE7H,MAAM,UAAU,EAAE,aAAa;CAC7B,MAAM;CACN,MAAM;CACN,OAAO,EAAE,MAAM,EAAE,CAAC,CAAC,SAAS;CAC5B,OAAO,EAAE,MAAM,IAAI,CAAC,CAAC,SAAS;AAChC,CAAC;;;;;AAMD,MAAa,cAAqC,EAAE,aAAa;CAC/D,QAAQ,EAAE,QAAQ,YAAY;CAC9B,WAAW,EAAE,MAAM,QAAQ,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACjD,UAAU,EAAE,MAAM,OAAO,CAAC,CAAC,SAAS;AACtC,CAAC;;;;;AASD,SAAgB,WAAW,OAA4B;CACrD,MAAM,OAAO,YAAY,UAAU,KAAK;CACxC,IAAI,KAAK,SAAS,OAAO;EAAE,IAAI;EAAM,OAAO,KAAK;CAAK;CACtD,OAAO;EAAE,IAAI;EAAO,QAAQ,WAAW,cAAc,KAAK,MAAM,MAAM;CAAE;AAC1E"}
package/package.json CHANGED
@@ -1,6 +1,78 @@
1
1
  {
2
+ "$schema": "https://json.schemastore.org/package",
2
3
  "name": "@mark1russell7/stack-setup",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
4
+ "version": "0.1.0",
5
+ "description": "The setup inside a host from the records of a system stack: typed steps, their order from the needs, a gate, and a POSIX shell script that checks before it changes. An add-on of system-stack.",
6
+ "license": "MIT",
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "git+https://github.com/mark1russell7/system-stack.git",
10
+ "directory": "packages/stack-setup"
11
+ },
12
+ "homepage": "https://mark1russell7.github.io/system-stack/",
13
+ "bugs": {
14
+ "url": "https://github.com/mark1russell7/system-stack/issues"
15
+ },
16
+ "keywords": [
17
+ "setup",
18
+ "provisioning",
19
+ "shell-script",
20
+ "idempotent",
21
+ "systemd",
22
+ "apt",
23
+ "gate",
24
+ "system-stack"
25
+ ],
26
+ "type": "module",
27
+ "sideEffects": false,
28
+ "main": "./build/index.js",
29
+ "exports": {
30
+ ".": {
31
+ "types": "./build/index.d.ts",
32
+ "import": "./build/index.js",
33
+ "default": "./build/index.js"
34
+ },
35
+ "./schema": {
36
+ "types": "./build/schema.d.ts",
37
+ "import": "./build/schema.js",
38
+ "default": "./build/schema.js"
39
+ },
40
+ "./add-on": {
41
+ "types": "./build/add-on.d.ts",
42
+ "import": "./build/add-on.js",
43
+ "default": "./build/add-on.js"
44
+ },
45
+ "./package.json": "./package.json"
46
+ },
47
+ "files": [
48
+ "build"
49
+ ],
50
+ "dependencies": {
51
+ "@mark1russell7/collections": "^0.11.2",
52
+ "@mark1russell7/system-stack": "0.1.6",
53
+ "@mark1russell7/text": "^0.0.17",
54
+ "zod": "^4.6.7"
55
+ },
56
+ "devDependencies": {
57
+ "@mark1russell7/cue": "^2.0.0",
58
+ "@types/node": "^26.6.5",
59
+ "@vitest/coverage-v8": "^5.0.3",
60
+ "tsdown": "^0.23.1",
61
+ "typescript": "^7.0.2",
62
+ "vitest": "^5.0.3"
63
+ },
64
+ "engines": {
65
+ "node": ">=22"
66
+ },
67
+ "publishConfig": {
68
+ "access": "public"
69
+ },
70
+ "scripts": {
71
+ "build": "tsdown",
72
+ "test": "vitest run",
73
+ "test:watch": "vitest",
74
+ "test:setup": "node --test e2e/setup.e2e.ts",
75
+ "typecheck": "tsc -p tsconfig.json && tsc -p tsconfig.test.json"
76
+ },
77
+ "types": "./build/index.d.ts"
6
78
  }