@akala/pm 15.3.46 → 15.4.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.
Files changed (135) hide show
  1. package/changelog.md +1 -1
  2. package/dist/esm/akala.mjs +2 -0
  3. package/dist/esm/akala.mjs.map +1 -1
  4. package/dist/esm/cli-commands/$init.d.ts +4 -3
  5. package/dist/esm/cli-commands/$init.js +3 -2
  6. package/dist/esm/cli-commands/$init.js.map +1 -1
  7. package/dist/esm/cli-commands/connect.d.ts +2 -2
  8. package/dist/esm/cli-commands/connect.js.map +1 -1
  9. package/dist/esm/cli-commands/discover.js +2 -0
  10. package/dist/esm/cli-commands/discover.js.map +1 -1
  11. package/dist/esm/cli-commands/install.d.ts +1 -1
  12. package/dist/esm/cli-commands/install.js +2 -0
  13. package/dist/esm/cli-commands/install.js.map +1 -1
  14. package/dist/esm/cli-commands/link.d.ts +1 -1
  15. package/dist/esm/cli-commands/link.js +2 -0
  16. package/dist/esm/cli-commands/link.js.map +1 -1
  17. package/dist/esm/cli-commands/log.d.ts +1 -1
  18. package/dist/esm/cli-commands/log.js +1 -0
  19. package/dist/esm/cli-commands/log.js.map +1 -1
  20. package/dist/esm/cli-commands/ls.d.ts +1 -1
  21. package/dist/esm/cli-commands/map.d.ts +2 -1
  22. package/dist/esm/cli-commands/map.js.map +1 -1
  23. package/dist/esm/cli-commands/run.d.ts +1 -1
  24. package/dist/esm/cli-commands/run.js +3 -2
  25. package/dist/esm/cli-commands/run.js.map +1 -1
  26. package/dist/esm/cli-commands/start.d.ts +3 -3
  27. package/dist/esm/cli-commands/start.js +1 -0
  28. package/dist/esm/cli-commands/start.js.map +1 -1
  29. package/dist/esm/cli-commands/uninstall.d.ts +1 -1
  30. package/dist/esm/cli-commands/uninstall.js +1 -0
  31. package/dist/esm/cli-commands/uninstall.js.map +1 -1
  32. package/dist/esm/cli-commands/update.d.ts +1 -1
  33. package/dist/esm/cli-commands/update.js +1 -0
  34. package/dist/esm/cli-commands/update.js.map +1 -1
  35. package/dist/esm/cli-commands/version.d.ts +1 -1
  36. package/dist/esm/cli-container.d.ts +2 -2
  37. package/dist/esm/cli-container.js +1 -1
  38. package/dist/esm/cli-container.js.map +1 -1
  39. package/dist/esm/cli.js +1 -1
  40. package/dist/esm/cli.js.map +1 -1
  41. package/dist/esm/commands/$init.d.ts +4 -3
  42. package/dist/esm/commands/$init.js +3 -0
  43. package/dist/esm/commands/$init.js.map +1 -1
  44. package/dist/esm/commands/bridge.d.ts +2 -2
  45. package/dist/esm/commands/bridge.js +1 -0
  46. package/dist/esm/commands/bridge.js.map +1 -1
  47. package/dist/esm/commands/proxy.d.ts +2 -2
  48. package/dist/esm/commands/proxy.js +1 -0
  49. package/dist/esm/commands/proxy.js.map +1 -1
  50. package/dist/esm/commands/ready.d.ts +2 -1
  51. package/dist/esm/commands/ready.js +2 -1
  52. package/dist/esm/commands/ready.js.map +1 -1
  53. package/dist/esm/commands/reload-metadata.js +1 -1
  54. package/dist/esm/commands/reload-metadata.js.map +1 -1
  55. package/dist/esm/commands/restart.d.ts +2 -2
  56. package/dist/esm/commands/restart.js +3 -0
  57. package/dist/esm/commands/restart.js.map +1 -1
  58. package/dist/esm/commands/start.d.ts +2 -2
  59. package/dist/esm/commands/start.js +2 -0
  60. package/dist/esm/commands/start.js.map +1 -1
  61. package/dist/esm/commands/status.d.ts +1 -1
  62. package/dist/esm/commands/stop.d.ts +1 -1
  63. package/dist/esm/commands/stop.js +1 -0
  64. package/dist/esm/commands/stop.js.map +1 -1
  65. package/dist/esm/container.d.ts +2 -2
  66. package/dist/esm/container.js +1 -1
  67. package/dist/esm/container.js.map +1 -1
  68. package/dist/esm/index.d.ts +4 -4
  69. package/dist/esm/index.js +3 -0
  70. package/dist/esm/index.js.map +1 -1
  71. package/dist/esm/ipc-adapter.d.ts +2 -1
  72. package/dist/esm/ipc-adapter.js +2 -0
  73. package/dist/esm/ipc-adapter.js.map +1 -1
  74. package/dist/esm/messageport-adapter.d.ts +3 -2
  75. package/dist/esm/messageport-adapter.js +1 -1
  76. package/dist/esm/messageport-adapter.js.map +1 -1
  77. package/dist/esm/new-line-prefixer.d.ts +1 -1
  78. package/dist/esm/new-line-prefixer.js.map +1 -1
  79. package/dist/esm/runtimes/child_process.d.ts +3 -3
  80. package/dist/esm/runtimes/child_process.js +2 -1
  81. package/dist/esm/runtimes/child_process.js.map +1 -1
  82. package/dist/esm/runtimes/process.d.ts +1 -1
  83. package/dist/esm/runtimes/process.js +1 -0
  84. package/dist/esm/runtimes/process.js.map +1 -1
  85. package/dist/esm/runtimes/shared.d.ts +2 -2
  86. package/dist/esm/runtimes/shared.js +1 -1
  87. package/dist/esm/runtimes/shared.js.map +1 -1
  88. package/dist/esm/runtimes/worker.d.ts +1 -1
  89. package/dist/esm/runtimes/worker.js +1 -0
  90. package/dist/esm/runtimes/worker.js.map +1 -1
  91. package/dist/esm/sidecar.d.ts +2 -2
  92. package/dist/esm/sidecar.js +2 -1
  93. package/dist/esm/sidecar.js.map +1 -1
  94. package/dist/esm/standalone.js +1 -1
  95. package/dist/esm/standalone.js.map +1 -1
  96. package/dist/esm/state.d.ts +4 -4
  97. package/dist/esm/state.js +2 -1
  98. package/dist/esm/state.js.map +1 -1
  99. package/dist/tsconfig.esm.tsbuildinfo +1 -1
  100. package/package.json +6 -6
  101. package/src/akala.mts +3 -3
  102. package/src/cli-commands/$init.ts +4 -3
  103. package/src/cli-commands/connect.ts +3 -3
  104. package/src/cli-commands/install.ts +1 -1
  105. package/src/cli-commands/link.ts +1 -1
  106. package/src/cli-commands/log.ts +2 -2
  107. package/src/cli-commands/ls.ts +2 -2
  108. package/src/cli-commands/map.ts +2 -1
  109. package/src/cli-commands/run.ts +3 -3
  110. package/src/cli-commands/start.ts +3 -3
  111. package/src/cli-commands/uninstall.ts +1 -1
  112. package/src/cli-commands/update.ts +2 -2
  113. package/src/cli-commands/version.ts +2 -2
  114. package/src/cli-container.ts +2 -2
  115. package/src/cli.ts +2 -1
  116. package/src/commands/$init.ts +4 -3
  117. package/src/commands/bridge.ts +3 -3
  118. package/src/commands/proxy.ts +3 -3
  119. package/src/commands/ready.ts +2 -1
  120. package/src/commands/restart.ts +2 -2
  121. package/src/commands/start.ts +5 -4
  122. package/src/commands/status.ts +1 -1
  123. package/src/commands/stop.ts +1 -1
  124. package/src/container.ts +2 -2
  125. package/src/index.ts +4 -4
  126. package/src/ipc-adapter.ts +2 -1
  127. package/src/messageport-adapter.ts +3 -2
  128. package/src/new-line-prefixer.ts +2 -2
  129. package/src/runtimes/child_process.ts +3 -3
  130. package/src/runtimes/process.ts +1 -1
  131. package/src/runtimes/shared.ts +2 -2
  132. package/src/runtimes/worker.ts +1 -1
  133. package/src/sidecar.ts +2 -2
  134. package/src/standalone.ts +2 -2
  135. package/src/state.ts +4 -4
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "pm": "dist/esm/cli.js",
5
5
  "pm-fork": "dist/esm/fork.js"
6
6
  },
7
- "version": "15.3.46",
7
+ "version": "15.4.0",
8
8
  "scripts": {
9
9
  "test": "echo 1",
10
10
  "generate": "akala sdk generate dist/esm/commands commands.json --name pm && akala sdk generate dist/esm/cli-commands cli-commands.json --name pm",
@@ -29,11 +29,11 @@
29
29
  "src/fork.ts"
30
30
  ],
31
31
  "dependencies": {
32
- "@akala/cli": "^5.11.16",
33
- "@akala/commands": "^17.2.17",
34
- "@akala/config": "^6.0.111",
35
- "@akala/core": "^41.0.3",
36
- "@akala/json-rpc-ws": "^12.0.25",
32
+ "@akala/cli": "^5.12.0",
33
+ "@akala/commands": "^17.3.0",
34
+ "@akala/config": "^6.1.0",
35
+ "@akala/core": "^41.1.0",
36
+ "@akala/json-rpc-ws": "^12.1.0",
37
37
  "reflect-metadata": "^0.2.2"
38
38
  },
39
39
  "devDependencies": {
package/src/akala.mts CHANGED
@@ -1,8 +1,8 @@
1
- import { Processors, Metadata, Container, Triggers, Cli, registerCommands, protocolHandlers, SelfDefinedCommand, StructuredParameters, ICommandProcessor, HandlerResult } from '@akala/commands';
1
+ import { Processors, Metadata, Container, Triggers, Cli, registerCommands, protocolHandlers, SelfDefinedCommand, type StructuredParameters, type ICommandProcessor, type HandlerResult } from '@akala/commands';
2
2
  import { Readable } from 'stream';
3
3
 
4
- import { StateConfiguration } from './state.js';
5
- import { CliContext, NamespaceMiddleware } from '@akala/cli';
4
+ import { type StateConfiguration } from './state.js';
5
+ import { type CliContext, NamespaceMiddleware } from '@akala/cli';
6
6
  import { eachAsync, HttpStatusCode, logger } from '@akala/core';
7
7
  import commands from './container.js';
8
8
  import cliCommands from './cli-container.js';
@@ -1,9 +1,10 @@
1
- import program, { CliContext } from "@akala/cli";
2
- import State, { StateConfiguration } from "../state.js";
1
+ import program, { type CliContext } from "@akala/cli";
2
+ import type State from "../state.js";
3
+ import type { StateConfiguration } from "../state.js";
3
4
  import { connect, Container } from "@akala/commands";
4
5
  import { platform } from "os";
5
6
  import { Triggers } from "@akala/commands";
6
- import { ProxyConfiguration } from "@akala/config";
7
+ import { type ProxyConfiguration } from "@akala/config";
7
8
  import { eachAsync, HttpStatusCode } from "@akala/core";
8
9
  import commands from "../container.js";
9
10
 
@@ -1,6 +1,6 @@
1
1
  import { ErrorWithStatus } from "@akala/core";
2
- import { serveMetadata, ServeOptions } from "@akala/commands";
3
- import State from '../state.js';
2
+ import { serveMetadata, type ServeOptions } from "@akala/commands";
3
+ import type State from '../state.js';
4
4
 
5
5
  export default async function connect(this: State, name: string): Promise<Record<string, object>>
6
6
  export default async function connect(this: State, name: string, context?: ServeOptions): Promise<void>
@@ -31,4 +31,4 @@ export default async function connect(this: State, name: string, context?: Serve
31
31
  return mapping.connect.extract();
32
32
  }
33
33
  await this.config.commit()
34
- }
34
+ }
@@ -1,4 +1,4 @@
1
- import State from '../state.js';
1
+ import type State from '../state.js';
2
2
  import npmHelper from '@akala/cli/npm-helper';
3
3
  import yarnHelper, { hasYarn } from '@akala/cli/yarn-helper';
4
4
  import { Container } from "@akala/commands";
@@ -1,4 +1,4 @@
1
- import State from '../state.js';
1
+ import type State from '../state.js';
2
2
  import npmHelper from '@akala/cli/npm-helper';
3
3
  import { Container } from "@akala/commands";
4
4
  import yarnHelper, { hasYarn } from '@akala/cli/yarn-helper';
@@ -1,6 +1,6 @@
1
1
  import { PassThrough } from "stream";
2
2
  import { Readable } from "stream";
3
- import State from '../state.js';
3
+ import type State from '../state.js';
4
4
 
5
5
  export default function log(this: State, name: string): Readable
6
6
  {
@@ -10,4 +10,4 @@ export default function log(this: State, name: string): Readable
10
10
  p.stderr.pipe(pt);
11
11
  p.stdout.pipe(pt);
12
12
  return pt;
13
- }
13
+ }
@@ -1,6 +1,6 @@
1
- import State from '../state.js';
1
+ import type State from '../state.js';
2
2
 
3
3
  export default function ls(this: State): State['config']['containers']
4
4
  {
5
5
  return this.config.containers;
6
- }
6
+ }
@@ -1,4 +1,5 @@
1
- import State, { SidecarMetadata } from '../state.js';
1
+ import type State from '../state.js';
2
+ import type { SidecarMetadata } from '../state.js';
2
3
  import { isAbsolute, resolve } from "path";
3
4
 
4
5
  export default async function map<TName extends string>(config: State['config'], name: TName, targetPath: string | URL, runtime: SidecarMetadata['type'], cwd?: string, options?: { commandable?: boolean })
@@ -2,10 +2,10 @@
2
2
  import path from 'path'
3
3
  import pmDef from '../container.js';
4
4
  import { module as coreModule } from '@akala/core';
5
- import { buildCliContextFromContext, CliContext, NamespaceMiddleware } from '@akala/cli';
6
- import { ServeMetadata, registerCommands, SelfDefinedCommand, Container, connectByPreference, Metadata, $metadata, protocolHandlers } from '@akala/commands';
5
+ import { buildCliContextFromContext, type CliContext, NamespaceMiddleware } from '@akala/cli';
6
+ import { type ServeMetadata, registerCommands, SelfDefinedCommand, Container, connectByPreference, Metadata, $metadata, protocolHandlers } from '@akala/commands';
7
7
  import { pathToFileURL } from 'url';
8
- import fsHandler, { Stats } from '@akala/fs';
8
+ import fsHandler, { type Stats } from '@akala/fs';
9
9
  import { Triggers } from '@akala/commands';
10
10
  import { backChannelContainer, remotePm } from '../akala.mjs';
11
11
 
@@ -1,6 +1,6 @@
1
- import State, { } from '../state.js';
2
- import { StdioOptions } from "child_process";
3
- import { CliContext, unparseOptions } from "@akala/cli";
1
+ import type State from '../state.js';
2
+ import { type StdioOptions } from "child_process";
3
+ import { type CliContext, unparseOptions } from "@akala/cli";
4
4
  import ChildProcess from '../runtimes/child_process.js'
5
5
 
6
6
  export default async function start(this: State, name: string, context?: CliContext<{ configFile: string, new?: boolean, name: string, keepAttached?: boolean, inspect?: boolean, verbose?: number, wait?: boolean }>): Promise<void | { execPath: string, args: string[], cwd: string, stdio: StdioOptions, shell: boolean, windowsHide: boolean }>
@@ -1,4 +1,4 @@
1
- import State from '../state.js';
1
+ import type State from '../state.js';
2
2
  import npmHelper from '@akala/cli/npm-helper';
3
3
  import yarnHelper, { hasYarn } from '@akala/cli/yarn-helper';
4
4
  import { Container } from "@akala/commands";
@@ -1,4 +1,4 @@
1
- import State from '../state.js';
1
+ import type State from '../state.js';
2
2
  import npmHelper from '@akala/cli/npm-helper';
3
3
  import { Container } from "@akala/commands";
4
4
  import yarnHelper, { hasYarn } from '@akala/cli/yarn-helper';
@@ -19,4 +19,4 @@ export default async function update(this: State, packageName: string, folder: s
19
19
  }
20
20
 
21
21
  return 'updated from ' + version + ' to ' + await pm.dispatch('version', packageName, folder);
22
- }
22
+ }
@@ -1,4 +1,4 @@
1
- import State from '../state.js';
1
+ import type State from '../state.js';
2
2
  import { join } from "path";
3
3
 
4
4
 
@@ -14,4 +14,4 @@ export default async function version(this: State, packageName: string, folder:
14
14
  delete require.cache[join(path, 'node_modules', packageName, './package.json')];
15
15
  }
16
16
  return packageConfig.default.version;
17
- }
17
+ }
@@ -1,8 +1,8 @@
1
1
  //eslint-disable-next-line @typescript-eslint/ban-ts-comment
2
2
  //@ts-ignore 6133
3
3
  //eslint-disable-next-line @typescript-eslint/no-unused-vars
4
- import {Arguments, Argument0, Argument1, Argument2, Argument3, Argument4, Argument5, Argument6, Argument7, Argument8, Argument9, Argument10, Argument11, Argument12, Argument13, Argument14, Argument15, Argument16, Argument17 } from '@akala/core';
5
- import {Metadata, ICommandProcessor, Container, registerCommands} from "@akala/commands";
4
+ import type {Arguments, Argument0, Argument1, Argument2, Argument3, Argument4, Argument5, Argument6, Argument7, Argument8, Argument9, Argument10, Argument11, Argument12, Argument13, Argument14, Argument15, Argument16, Argument17 } from '@akala/core';
5
+ import {Metadata, type ICommandProcessor, Container, registerCommands} from "@akala/commands";
6
6
  // eslint-disable-next-line @typescript-eslint/no-namespace
7
7
  namespace cliCommands
8
8
  {
package/src/cli.ts CHANGED
@@ -6,7 +6,8 @@ import { platform } from 'os';
6
6
  import start from './cli-commands/start.js'
7
7
  import { Readable } from 'stream';
8
8
 
9
- import State, { StateConfiguration } from './state.js';
9
+ import type State from './state.js';
10
+ import type { StateConfiguration } from './state.js';
10
11
  import { program, buildCliContextFromProcess, ErrorMessage, supportInteract } from '@akala/cli';
11
12
  import { open } from 'fs/promises';
12
13
  import { LogLevels } from '@akala/core';
@@ -1,10 +1,11 @@
1
- import State, { RunningContainer, StateConfiguration } from '../state.js'
1
+ import type State from '../state.js'
2
+ import type { RunningContainer, StateConfiguration } from '../state.js'
2
3
  import fs from 'fs/promises';
3
4
  import pmContainer from '../container.js';
4
5
  import { Container, Metadata, ignoredCommands, configure, SelfDefinedCommand } from '@akala/commands';
5
6
  import { PassThrough } from 'stream';
6
- import { CliContext } from '@akala/cli';
7
- import { ProxyConfiguration } from '@akala/config';
7
+ import { type CliContext } from '@akala/cli';
8
+ import { type ProxyConfiguration } from '@akala/config';
8
9
  import { fileURLToPath } from 'url';
9
10
  import { eachAsync, Event } from '@akala/core';
10
11
  import Process from '../runtimes/process.js';
@@ -1,5 +1,5 @@
1
- import { SocketAdapter } from "@akala/json-rpc-ws";
2
- import State from "../state.js";
1
+ import { type SocketAdapter } from "@akala/json-rpc-ws";
2
+ import type State from "../state.js";
3
3
 
4
4
  export default function (this: State, connectionId: string, socket: SocketAdapter)
5
5
  {
@@ -11,4 +11,4 @@ export default function (this: State, connectionId: string, socket: SocketAdapte
11
11
  this.bridges[connectionId].left.on('close', () => socket.close());
12
12
  this.bridges[connectionId].right = socket;
13
13
  return true;
14
- }
14
+ }
@@ -1,7 +1,7 @@
1
1
  import { ErrorWithStatus } from "@akala/core";
2
- import { SocketAdapter } from "@akala/json-rpc-ws";
2
+ import { type SocketAdapter } from "@akala/json-rpc-ws";
3
3
  import { randomUUID } from "crypto";
4
- import State from "../state.js";
4
+ import type State from "../state.js";
5
5
 
6
6
  export default async function (this: State, name: string, socket: SocketAdapter)
7
7
  {
@@ -22,4 +22,4 @@ export default async function (this: State, name: string, socket: SocketAdapter)
22
22
  }
23
23
  }, 100)
24
24
  });
25
- }
25
+ }
@@ -1,6 +1,7 @@
1
1
  import { $metadata, Container, Metadata, registerCommands, SelfDefinedCommand } from '@akala/commands';
2
2
  import pm from '../container.js';
3
- import State, { RunningContainer } from '../state.js';
3
+ import type { RunningContainer } from '../state.js';
4
+ import type State from '../state.js';
4
5
 
5
6
  export default async function ready(this: State, pm: pm.container & Container<State>, container: RunningContainer, standaloneContainer: RunningContainer): Promise<void>
6
7
  {
@@ -1,6 +1,6 @@
1
- import { StdioOptions } from "child_process";
1
+ import { type StdioOptions } from "child_process";
2
2
  import pmContainer from '../container.js';
3
- import { CliContext } from "@akala/cli";
3
+ import { type CliContext } from "@akala/cli";
4
4
 
5
5
  export default async function restart(pm: pmContainer.container, name: string, context?: CliContext<{ new?: boolean, name: string, inspect?: boolean, verbose?: number, wait?: boolean }>): Promise<void | { execPath: string, args: string[], cwd: string, stdio: StdioOptions, shell: boolean, windowsHide: boolean }>
6
6
  {
@@ -1,13 +1,14 @@
1
1
  import { Container, Processors, Metadata, Cli, updateCommands } from "@akala/commands";
2
- import State, { RunningContainer, SidecarMetadata } from '../state.js';
2
+ import type { RunningContainer, SidecarMetadata } from '../state.js';
3
+ import type State from '../state.js';
3
4
  import pmContainer from '../container.js';
4
5
  import { eachAsync, Event, ErrorWithStatus, sequencify, HttpStatusCode } from "@akala/core";
5
- import { CliContext, unparseOptions } from "@akala/cli";
6
+ import { type CliContext, unparseOptions } from "@akala/cli";
6
7
  import getRandomName from "./name.js";
7
- import { ProxyConfiguration, unwrap } from "@akala/config";
8
+ import { type ProxyConfiguration, unwrap } from "@akala/config";
8
9
  import path from 'path'
9
10
  import { fileURLToPath } from 'url'
10
- import { RuntimeInstance } from "../runtimes/shared.js";
11
+ import { type RuntimeInstance } from "../runtimes/shared.js";
11
12
  import ChildProcess from "../runtimes/child_process.js";
12
13
  import Worker from "../runtimes/worker.js";
13
14
 
@@ -1,4 +1,4 @@
1
- import State from '../state.js';
1
+ import type State from '../state.js';
2
2
 
3
3
  export default function status(this: State, name?: string): { name: string, filter: string, running: boolean, folder: string }[]
4
4
  {
@@ -1,5 +1,5 @@
1
1
  import { Container } from "@akala/commands";
2
- import State from '../state.js';
2
+ import type State from '../state.js';
3
3
 
4
4
  export default async function stop(this: State, name: string, container: Container<State>): Promise<void>
5
5
  {
package/src/container.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  //eslint-disable-next-line @typescript-eslint/ban-ts-comment
2
2
  //@ts-ignore 6133
3
3
  //eslint-disable-next-line @typescript-eslint/no-unused-vars
4
- import {Arguments, Argument0, Argument1, Argument2, Argument3, Argument4, Argument5, Argument6, Argument7, Argument8, Argument9, Argument10, Argument11, Argument12, Argument13, Argument14, Argument15, Argument16, Argument17 } from '@akala/core';
5
- import {Metadata, ICommandProcessor, Container, registerCommands} from "@akala/commands";
4
+ import type {Arguments, Argument0, Argument1, Argument2, Argument3, Argument4, Argument5, Argument6, Argument7, Argument8, Argument9, Argument10, Argument11, Argument12, Argument13, Argument14, Argument15, Argument16, Argument17 } from '@akala/core';
5
+ import {Metadata, type ICommandProcessor, Container, registerCommands} from "@akala/commands";
6
6
  // eslint-disable-next-line @typescript-eslint/no-namespace
7
7
  namespace commands
8
8
  {
package/src/index.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Container, Metadata, ServeMetadata, ConnectionPreference } from "@akala/commands";
1
+ import { Container, Metadata, type ServeMetadata, type ConnectionPreference } from "@akala/commands";
2
2
  import { module } from "@akala/core";
3
3
 
4
4
  import definition from './container.js';
@@ -7,10 +7,10 @@ type pmContainer = definition.container
7
7
 
8
8
  export const meta = definition.meta;
9
9
 
10
- export { pmContainer as Container, };
10
+ export { type pmContainer as Container, };
11
11
 
12
- import State from './state.js'
13
- export { State }
12
+ import type State from './state.js'
13
+ export { type State }
14
14
 
15
15
  export default function interact(message: string, as?: string): void
16
16
  {
@@ -1,6 +1,7 @@
1
1
  import { ChildProcess } from "child_process";
2
2
  import * as jsonrpc from '@akala/json-rpc-ws';
3
- import { AllEventKeys, AllEvents, ErrorWithStatus, EventArgs, EventListener, EventOptions, EventReturnType, StatefulSubscription, Subscription, AsyncTeardownManager } from "@akala/core";
3
+ import type { AllEventKeys, AllEvents, EventArgs, EventListener, EventOptions, EventReturnType, Subscription } from "@akala/core";
4
+ import { ErrorWithStatus, StatefulSubscription, AsyncTeardownManager } from "@akala/core";
4
5
 
5
6
  export class IpcAdapter extends AsyncTeardownManager implements jsonrpc.SocketAdapter
6
7
  {
@@ -1,5 +1,6 @@
1
- import { AllEventKeys, AllEvents, ErrorWithStatus, EventArgs, EventListener, EventOptions, EventReturnType, StatefulSubscription, Subscription, AsyncTeardownManager } from "@akala/core";
2
- import { SocketAdapter, SocketAdapterAkalaEventMap } from "@akala/json-rpc-ws";
1
+ import type { AllEventKeys, AllEvents, EventArgs, EventListener, EventOptions, EventReturnType, Subscription } from "@akala/core";
2
+ import { ErrorWithStatus, StatefulSubscription, AsyncTeardownManager } from "@akala/core";
3
+ import type { SocketAdapter, SocketAdapterAkalaEventMap } from "@akala/json-rpc-ws";
3
4
  import { MessagePort, Worker } from "worker_threads";
4
5
 
5
6
  export class MessagePortAdapter extends AsyncTeardownManager implements SocketAdapter
@@ -1,4 +1,4 @@
1
- import { Transform, TransformCallback } from "stream";
1
+ import { Transform, type TransformCallback } from "stream";
2
2
 
3
3
  interface Options
4
4
  {
@@ -57,4 +57,4 @@ export class NewLinePrefixer extends Transform
57
57
  callback(null, chunk.replace(/\n([^$])/g, `\n${this.prefix}$1`))
58
58
 
59
59
  }
60
- }
60
+ }
@@ -1,9 +1,9 @@
1
- import { ChildProcess, SendHandle, Serializable, spawn } from "child_process";
1
+ import { ChildProcess, type SendHandle, type Serializable, spawn } from "child_process";
2
2
  import { Readable } from "stream";
3
3
  import { IpcAdapter } from "../ipc-adapter.js";
4
4
  import { NewLinePrefixer } from "../new-line-prefixer.js";
5
- import { RuntimeEventMap, RuntimeInstance } from "./shared.js";
6
- import { EventEmitter, IEvent } from "@akala/core";
5
+ import type { RuntimeEventMap, RuntimeInstance } from "./shared.js";
6
+ import { EventEmitter, type IEvent } from "@akala/core";
7
7
  import { fileURLToPath } from "url";
8
8
 
9
9
  export type ChildProcessRuntimeEventMap = {
@@ -1,6 +1,6 @@
1
1
  import { Readable, Writable } from "stream";
2
2
  import { IpcAdapter } from "../ipc-adapter.js";
3
- import { RuntimeEventMap, RuntimeInstance } from "./shared.js";
3
+ import type { RuntimeEventMap, RuntimeInstance } from "./shared.js";
4
4
  import { EventEmitter } from "@akala/core";
5
5
 
6
6
  export default class Runtime extends EventEmitter<RuntimeEventMap> implements RuntimeInstance
@@ -1,5 +1,5 @@
1
- import { IEvent, EventBus, SpecialEvents } from "@akala/core";
2
- import { SocketAdapter } from "@akala/json-rpc-ws";
1
+ import type { IEvent, EventBus, SpecialEvents } from "@akala/core";
2
+ import type { SocketAdapter } from "@akala/json-rpc-ws";
3
3
  import { Readable } from "stream";
4
4
 
5
5
  export interface Runtime
@@ -2,7 +2,7 @@ import { Worker } from "worker_threads";
2
2
  import { Readable } from "stream";
3
3
  import { NewLinePrefixer } from "../new-line-prefixer.js";
4
4
  import { MessagePortAdapter } from "../messageport-adapter.js";
5
- import { RuntimeEventMap, RuntimeInstance } from "./shared.js";
5
+ import type { RuntimeEventMap, RuntimeInstance } from "./shared.js";
6
6
  import module from 'module'
7
7
  import { EventEmitter } from "@akala/core";
8
8
  const require = module.createRequire(import.meta.url);
package/src/sidecar.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { module } from '@akala/core'
2
- import { $metadata, connectByPreference, ConnectionPreference, Container, updateCommands } from "@akala/commands";
3
- import { SideCarConnectionPreference, Sidecar, defaultOrders, connect } from "./index.js";
2
+ import { $metadata, connectByPreference, type ConnectionPreference, Container, updateCommands } from "@akala/commands";
3
+ import { type SideCarConnectionPreference, type Sidecar, defaultOrders, connect } from "./index.js";
4
4
  import pm from './container.js'
5
5
 
6
6
  let instance: Sidecar;
package/src/standalone.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
2
  import * as path from 'path'
3
3
  import * as ac from '@akala/commands';
4
- import { convertToMiddleware, logger, Logger, MiddlewareCompositeAsync } from '@akala/core';
4
+ import { convertToMiddleware, logger, type Logger, MiddlewareCompositeAsync } from '@akala/core';
5
5
  import { program, buildCliContextFromProcess, ErrorMessage, NamespaceMiddleware } from '@akala/cli';
6
- import fsHandler, { Stats } from '@akala/fs';
6
+ import fsHandler, { type Stats } from '@akala/fs';
7
7
  import { pathToFileURL } from 'url';
8
8
 
9
9
  program.option('help')
package/src/state.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { Container } from "@akala/commands";
2
- import { Event, SerializableObject } from "@akala/core";
3
- import { SocketAdapter } from "@akala/json-rpc-ws";
4
- import { ProxyConfiguration } from "@akala/config";
5
- import { RuntimeInstance } from "./runtimes/shared.js";
2
+ import { Event, type SerializableObject } from "@akala/core";
3
+ import type { SocketAdapter } from "@akala/json-rpc-ws";
4
+ import type { ProxyConfiguration } from "@akala/config";
5
+ import type { RuntimeInstance } from "./runtimes/shared.js";
6
6
 
7
7
  export default interface State
8
8
  {