@tsplc/build 0.5.9 → 0.5.10

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/src/index.ts CHANGED
@@ -18,7 +18,9 @@ export {
18
18
  type ControllerLogin,
19
19
  findControllerLogin,
20
20
  inspectController,
21
+ type OnlineChangeReview,
21
22
  openControllerLogin,
23
+ reviewWarmController,
22
24
  settleWarmController,
23
25
  startWarmController,
24
26
  updateController,
@@ -26,6 +28,7 @@ export {
26
28
  } from "./controller-online";
27
29
  export {
28
30
  type ControllerResult,
31
+ DownloadRequiredError,
29
32
  explicitDownload,
30
33
  failureReason,
31
34
  type LoginCommand,
@@ -63,6 +66,11 @@ export {
63
66
  libraryIndex,
64
67
  validateLibrary,
65
68
  } from "./libraries";
69
+ export {
70
+ describeFinding,
71
+ type OnlineChangeFinding,
72
+ onlineChangeFindingSchema,
73
+ } from "./online-change-check";
66
74
  export {
67
75
  checkRawSources,
68
76
  inspectProjectController,
@@ -25,15 +25,16 @@ export const committedObjectSchema: z.ZodType<CommittedObject> = z.lazy(() =>
25
25
  * refusal is what CODESYS would refuse or apply wrongly, so the deploy offers a download before
26
26
  * CODESYS runs; anything else is a warning about state the change restarts.
27
27
  */
28
- export interface OnlineChangeFinding {
29
- kind: "type" | "tasks" | "restart";
30
- refuses: boolean;
31
- object: string;
32
- variable: string | null;
33
- before: string | null;
34
- after: string | null;
35
- advice: string;
36
- }
28
+ export const onlineChangeFindingSchema = z.strictObject({
29
+ kind: z.enum(["type", "tasks", "restart"]),
30
+ refuses: z.boolean(),
31
+ object: z.string(),
32
+ variable: z.string().nullable(),
33
+ before: z.string().nullable(),
34
+ after: z.string().nullable(),
35
+ advice: z.string(),
36
+ });
37
+ export type OnlineChangeFinding = z.infer<typeof onlineChangeFindingSchema>;
37
38
 
38
39
  /** Objects whose variables keep their values across scans; a routine's own variables don't. */
39
40
  const keepsState = (kind: string) =>