@stryke/capnp 0.10.2 → 0.10.3

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/bin/capnpc.cjs CHANGED
@@ -7970,11 +7970,13 @@ async function resolveOptions(options) {
7970
7970
  });
7971
7971
  return null;
7972
7972
  }
7973
- resolvedTsconfig.options.outDir = joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
7973
+ const output = options.output ? options.output.replace("{projectRoot}", options.projectRoot).replace("{workspaceRoot}", options.workspaceRoot) : joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
7974
+ resolvedTsconfig.options.outDir = output;
7974
7975
  return {
7975
7976
  workspaceRoot: options.workspaceRoot,
7976
7977
  projectRoot: options.projectRoot,
7977
7978
  schemas: resolvedSchemas,
7979
+ output,
7978
7980
  js: options.js ?? false,
7979
7981
  ts: options.ts ?? (options.noTs !== void 0 ? !options.noTs : true),
7980
7982
  dts: options.dts ?? (options.noDts !== void 0 ? !options.noDts : true),
@@ -8006,6 +8008,10 @@ async function capnpc(options) {
8006
8008
  if (dataBuf.byteLength === 0) {
8007
8009
  const opts = [];
8008
8010
  if (output) {
8011
+ if (!existsSync(output)) {
8012
+ (0, import_console2.writeWarning)(`Output directory "${output}" does not exist, it will be created...`);
8013
+ await createDirectory(output);
8014
+ }
8009
8015
  opts.push(`-o-:${output}`);
8010
8016
  } else {
8011
8017
  opts.push("-o-");
package/bin/capnpc.js CHANGED
@@ -7939,11 +7939,13 @@ async function resolveOptions(options) {
7939
7939
  });
7940
7940
  return null;
7941
7941
  }
7942
- resolvedTsconfig.options.outDir = joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
7942
+ const output = options.output ? options.output.replace("{projectRoot}", options.projectRoot).replace("{workspaceRoot}", options.workspaceRoot) : joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
7943
+ resolvedTsconfig.options.outDir = output;
7943
7944
  return {
7944
7945
  workspaceRoot: options.workspaceRoot,
7945
7946
  projectRoot: options.projectRoot,
7946
7947
  schemas: resolvedSchemas,
7948
+ output,
7947
7949
  js: options.js ?? false,
7948
7950
  ts: options.ts ?? (options.noTs !== void 0 ? !options.noTs : true),
7949
7951
  dts: options.dts ?? (options.noDts !== void 0 ? !options.noDts : true),
@@ -7975,6 +7977,10 @@ async function capnpc(options) {
7975
7977
  if (dataBuf.byteLength === 0) {
7976
7978
  const opts = [];
7977
7979
  if (output) {
7980
+ if (!existsSync(output)) {
7981
+ writeWarning2(`Output directory "${output}" does not exist, it will be created...`);
7982
+ await createDirectory(output);
7983
+ }
7978
7984
  opts.push(`-o-:${output}`);
7979
7985
  } else {
7980
7986
  opts.push("-o-");
@@ -1,6 +1,8 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; } var _class; var _class2; var _class3; var _class4; var _class5; var _class6; var _class7; var _class8; var _class9; var _class10; var _class11; var _class12; var _class13; var _class14; var _class15; var _class16; var _class17; var _class18; var _class19; var _class20; var _class21; var _class22; var _class23; var _class24; var _class25; var _class26; var _class27; var _class28; var _class29; var _class30; var _class31; var _class32; var _class33; var _class34; var _class35; var _class36; var _class37;
2
2
 
3
- var _chunk3ZOLKZQQcjs = require('./chunk-3ZOLKZQQ.cjs');
3
+
4
+
5
+ var _chunkL3LVFSZKcjs = require('./chunk-L3LVFSZK.cjs');
4
6
 
5
7
 
6
8
 
@@ -4053,6 +4055,10 @@ async function capnpc(options) {
4053
4055
  if (dataBuf.byteLength === 0) {
4054
4056
  const opts = [];
4055
4057
  if (output) {
4058
+ if (!_chunkL3LVFSZKcjs.existsSync.call(void 0, output)) {
4059
+ _console.writeWarning.call(void 0, `Output directory "${output}" does not exist, it will be created...`);
4060
+ await _chunkL3LVFSZKcjs.createDirectory.call(void 0, output);
4061
+ }
4056
4062
  opts.push(`-o-:${output}`);
4057
4063
  } else {
4058
4064
  opts.push("-o-");
@@ -4080,7 +4086,7 @@ async function capnpc(options) {
4080
4086
  }
4081
4087
  _chunkUSNT2KNTcjs.__name.call(void 0, capnpc, "capnpc");
4082
4088
  async function compile(dataBuf, options) {
4083
- const resolvedOptions = await _chunk3ZOLKZQQcjs.resolveOptions.call(void 0, options);
4089
+ const resolvedOptions = await _chunkL3LVFSZKcjs.resolveOptions.call(void 0, options);
4084
4090
  if (!resolvedOptions) {
4085
4091
  _console.writeWarning.call(void 0, "\u2716 Unable to resolve Cap'n Proto compiler options - the program will terminate", {
4086
4092
  logLevel: "all"
@@ -750,6 +750,9 @@ _chunkUSNT2KNTcjs.__name.call(void 0, normalizeWindowsPath2, "normalizeWindowsPa
750
750
  var existsSync2 = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, (filePath) => {
751
751
  return _fs.existsSync.call(void 0, filePath);
752
752
  }, "existsSync");
753
+ var exists = /* @__PURE__ */ _chunkUSNT2KNTcjs.__name.call(void 0, async (filePath) => {
754
+ return _promises.access.call(void 0, filePath, _promises.constants.F_OK).then(() => true).catch(() => false);
755
+ }, "exists");
753
756
 
754
757
  // ../path/src/file-path-fns.ts
755
758
  var _path = require('path');
@@ -791,6 +794,15 @@ _chunkUSNT2KNTcjs.__name.call(void 0, relativePath, "relativePath");
791
794
  var _nanotar = require('nanotar');
792
795
 
793
796
 
797
+ async function createDirectory(path) {
798
+ if (await exists(path)) {
799
+ return;
800
+ }
801
+ return _promises.mkdir.call(void 0, path, {
802
+ recursive: true
803
+ });
804
+ }
805
+ _chunkUSNT2KNTcjs.__name.call(void 0, createDirectory, "createDirectory");
794
806
 
795
807
  // ../fs/src/json.ts
796
808
  async function readJsonFile(path, options) {
@@ -877,11 +889,13 @@ async function resolveOptions(options) {
877
889
  });
878
890
  return null;
879
891
  }
880
- resolvedTsconfig.options.outDir = joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
892
+ const output = options.output ? options.output.replace("{projectRoot}", options.projectRoot).replace("{workspaceRoot}", options.workspaceRoot) : joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
893
+ resolvedTsconfig.options.outDir = output;
881
894
  return {
882
895
  workspaceRoot: options.workspaceRoot,
883
896
  projectRoot: options.projectRoot,
884
897
  schemas: resolvedSchemas,
898
+ output,
885
899
  js: _nullishCoalesce(options.js, () => ( false)),
886
900
  ts: _nullishCoalesce(options.ts, () => ( (options.noTs !== void 0 ? !options.noTs : true))),
887
901
  dts: _nullishCoalesce(options.dts, () => ( (options.noDts !== void 0 ? !options.noDts : true))),
@@ -892,4 +906,6 @@ _chunkUSNT2KNTcjs.__name.call(void 0, resolveOptions, "resolveOptions");
892
906
 
893
907
 
894
908
 
895
- exports.resolveOptions = resolveOptions;
909
+
910
+
911
+ exports.existsSync = existsSync2; exports.createDirectory = createDirectory; exports.resolveOptions = resolveOptions;
@@ -1,6 +1,8 @@
1
1
  import {
2
+ createDirectory,
3
+ existsSync,
2
4
  resolveOptions
3
- } from "./chunk-3IOIINHW.js";
5
+ } from "./chunk-XU7T5EQG.js";
4
6
  import {
5
7
  CompositeList,
6
8
  Message,
@@ -4053,6 +4055,10 @@ async function capnpc(options) {
4053
4055
  if (dataBuf.byteLength === 0) {
4054
4056
  const opts = [];
4055
4057
  if (output) {
4058
+ if (!existsSync(output)) {
4059
+ writeWarning(`Output directory "${output}" does not exist, it will be created...`);
4060
+ await createDirectory(output);
4061
+ }
4056
4062
  opts.push(`-o-:${output}`);
4057
4063
  } else {
4058
4064
  opts.push("-o-");
@@ -750,6 +750,9 @@ import { access, constants } from "node:fs/promises";
750
750
  var existsSync2 = /* @__PURE__ */ __name((filePath) => {
751
751
  return existsSyncFs(filePath);
752
752
  }, "existsSync");
753
+ var exists = /* @__PURE__ */ __name(async (filePath) => {
754
+ return access(filePath, constants.F_OK).then(() => true).catch(() => false);
755
+ }, "exists");
753
756
 
754
757
  // ../path/src/file-path-fns.ts
755
758
  import { relative } from "node:path";
@@ -791,6 +794,15 @@ import { writeFile as writeFileFs } from "node:fs/promises";
791
794
  import { parseTar, parseTarGzip } from "nanotar";
792
795
  import { createWriteStream, mkdirSync, rmSync } from "node:fs";
793
796
  import { mkdir, readFile as readFile2, rm } from "node:fs/promises";
797
+ async function createDirectory(path) {
798
+ if (await exists(path)) {
799
+ return;
800
+ }
801
+ return mkdir(path, {
802
+ recursive: true
803
+ });
804
+ }
805
+ __name(createDirectory, "createDirectory");
794
806
 
795
807
  // ../fs/src/json.ts
796
808
  async function readJsonFile(path, options) {
@@ -877,11 +889,13 @@ async function resolveOptions(options) {
877
889
  });
878
890
  return null;
879
891
  }
880
- resolvedTsconfig.options.outDir = joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
892
+ const output = options.output ? options.output.replace("{projectRoot}", options.projectRoot).replace("{workspaceRoot}", options.workspaceRoot) : joinPaths(options.projectRoot, relativePath(tsconfigPath ? findFilePath(tsconfigPath) : options.projectRoot, joinPaths(options.workspaceRoot, resolvedSchemas[0].endsWith(".capnp") ? findFilePath(resolvedSchemas[0]) : resolvedSchemas[0])));
893
+ resolvedTsconfig.options.outDir = output;
881
894
  return {
882
895
  workspaceRoot: options.workspaceRoot,
883
896
  projectRoot: options.projectRoot,
884
897
  schemas: resolvedSchemas,
898
+ output,
885
899
  js: options.js ?? false,
886
900
  ts: options.ts ?? (options.noTs !== void 0 ? !options.noTs : true),
887
901
  dts: options.dts ?? (options.noDts !== void 0 ? !options.noDts : true),
@@ -891,5 +905,7 @@ async function resolveOptions(options) {
891
905
  __name(resolveOptions, "resolveOptions");
892
906
 
893
907
  export {
908
+ existsSync2 as existsSync,
909
+ createDirectory,
894
910
  resolveOptions
895
911
  };
package/dist/compile.cjs CHANGED
@@ -1,11 +1,11 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
3
 
4
- var _chunk55455L4Mcjs = require('./chunk-55455L4M.cjs');
5
- require('./chunk-3ZOLKZQQ.cjs');
4
+ var _chunkI7MRPN6Icjs = require('./chunk-I7MRPN6I.cjs');
5
+ require('./chunk-L3LVFSZK.cjs');
6
6
  require('./chunk-KXWOF6H4.cjs');
7
7
  require('./chunk-USNT2KNT.cjs');
8
8
 
9
9
 
10
10
 
11
- exports.capnpc = _chunk55455L4Mcjs.capnpc; exports.compile = _chunk55455L4Mcjs.compile;
11
+ exports.capnpc = _chunkI7MRPN6Icjs.capnpc; exports.compile = _chunkI7MRPN6Icjs.compile;
package/dist/compile.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  capnpc,
3
3
  compile
4
- } from "./chunk-GWW6WBAL.js";
5
- import "./chunk-3IOIINHW.js";
4
+ } from "./chunk-SW7GJVYC.js";
5
+ import "./chunk-XU7T5EQG.js";
6
6
  import "./chunk-5VHN3KGS.js";
7
7
  import "./chunk-SHUYVCID.js";
8
8
  export {
package/dist/helpers.cjs CHANGED
@@ -1,7 +1,7 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunk3ZOLKZQQcjs = require('./chunk-3ZOLKZQQ.cjs');
3
+ var _chunkL3LVFSZKcjs = require('./chunk-L3LVFSZK.cjs');
4
4
  require('./chunk-USNT2KNT.cjs');
5
5
 
6
6
 
7
- exports.resolveOptions = _chunk3ZOLKZQQcjs.resolveOptions;
7
+ exports.resolveOptions = _chunkL3LVFSZKcjs.resolveOptions;
package/dist/helpers.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  resolveOptions
3
- } from "./chunk-3IOIINHW.js";
3
+ } from "./chunk-XU7T5EQG.js";
4
4
  import "./chunk-SHUYVCID.js";
5
5
  export {
6
6
  resolveOptions
package/dist/index.cjs CHANGED
@@ -1,8 +1,8 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
3
 
4
- var _chunk55455L4Mcjs = require('./chunk-55455L4M.cjs');
5
- require('./chunk-3ZOLKZQQ.cjs');
4
+ var _chunkI7MRPN6Icjs = require('./chunk-I7MRPN6I.cjs');
5
+ require('./chunk-L3LVFSZK.cjs');
6
6
 
7
7
 
8
8
 
@@ -135,4 +135,4 @@ require('./chunk-USNT2KNT.cjs');
135
135
 
136
136
 
137
137
 
138
- exports.AnyPointerList = _chunkIBMXNAOTcjs.AnyPointerList; exports.BoolList = _chunkIBMXNAOTcjs.BoolList; exports.CapnpRPC = _chunkIBMXNAOTcjs.CapnpRPC; exports.CodeGeneratorContext = _chunkR2JXWA7Qcjs.CodeGeneratorContext; exports.CompositeList = _chunkKXWOF6H4cjs.CompositeList; exports.Conn = _chunkIBMXNAOTcjs.Conn; exports.Data = _chunkKXWOF6H4cjs.Data; exports.DataList = _chunkIBMXNAOTcjs.DataList; exports.Deferred = _chunkIBMXNAOTcjs.Deferred; exports.DeferredTransport = _chunkIBMXNAOTcjs.DeferredTransport; exports.ErrorClient = _chunkKXWOF6H4cjs.ErrorClient; exports.Float32List = _chunkIBMXNAOTcjs.Float32List; exports.Float64List = _chunkIBMXNAOTcjs.Float64List; exports.Int16List = _chunkIBMXNAOTcjs.Int16List; exports.Int32List = _chunkIBMXNAOTcjs.Int32List; exports.Int64List = _chunkIBMXNAOTcjs.Int64List; exports.Int8List = _chunkIBMXNAOTcjs.Int8List; exports.Interface = _chunkIBMXNAOTcjs.Interface; exports.InterfaceList = _chunkIBMXNAOTcjs.InterfaceList; exports.List = _chunkKXWOF6H4cjs.List; exports.ListElementSize = _chunkKXWOF6H4cjs.ListElementSize; exports.Message = _chunkKXWOF6H4cjs.Message; exports.MessageChannelTransport = _chunkIBMXNAOTcjs.MessageChannelTransport; exports.ObjectSize = _chunkKXWOF6H4cjs.ObjectSize; exports.Orphan = _chunkKXWOF6H4cjs.Orphan; exports.Pipeline = _chunkIBMXNAOTcjs.Pipeline; exports.Pointer = _chunkKXWOF6H4cjs.Pointer; exports.PointerList = _chunkIBMXNAOTcjs.PointerList; exports.PointerType = _chunkKXWOF6H4cjs.PointerType; exports.Registry = _chunkIBMXNAOTcjs.Registry; exports.Server = _chunkIBMXNAOTcjs.Server; exports.Struct = _chunkKXWOF6H4cjs.Struct; exports.Text = _chunkKXWOF6H4cjs.Text; exports.TextList = _chunkIBMXNAOTcjs.TextList; exports.Uint16List = _chunkIBMXNAOTcjs.Uint16List; exports.Uint32List = _chunkIBMXNAOTcjs.Uint32List; exports.Uint64List = _chunkIBMXNAOTcjs.Uint64List; exports.Uint8List = _chunkIBMXNAOTcjs.Uint8List; exports.Void = _chunkIBMXNAOTcjs.Void; exports.VoidList = _chunkIBMXNAOTcjs.VoidList; exports.answerPipelineClient = _chunkIBMXNAOTcjs.answerPipelineClient; exports.capnpc = _chunk55455L4Mcjs.capnpc; exports.clientFromResolution = _chunkIBMXNAOTcjs.clientFromResolution; exports.clientOrNull = _chunkKXWOF6H4cjs.clientOrNull; exports.compile = _chunk55455L4Mcjs.compile; exports.copyCall = _chunkIBMXNAOTcjs.copyCall; exports.getBitMask = _chunkKXWOF6H4cjs.getBitMask; exports.getFloat32Mask = _chunkKXWOF6H4cjs.getFloat32Mask; exports.getFloat64Mask = _chunkKXWOF6H4cjs.getFloat64Mask; exports.getInt16Mask = _chunkKXWOF6H4cjs.getInt16Mask; exports.getInt32Mask = _chunkKXWOF6H4cjs.getInt32Mask; exports.getInt64Mask = _chunkKXWOF6H4cjs.getInt64Mask; exports.getInt8Mask = _chunkKXWOF6H4cjs.getInt8Mask; exports.getUint16Mask = _chunkKXWOF6H4cjs.getUint16Mask; exports.getUint32Mask = _chunkKXWOF6H4cjs.getUint32Mask; exports.getUint64Mask = _chunkKXWOF6H4cjs.getUint64Mask; exports.getUint8Mask = _chunkKXWOF6H4cjs.getUint8Mask; exports.isDataCall = _chunkIBMXNAOTcjs.isDataCall; exports.isFuncCall = _chunkIBMXNAOTcjs.isFuncCall; exports.isSameClient = _chunkIBMXNAOTcjs.isSameClient; exports.placeParams = _chunkIBMXNAOTcjs.placeParams; exports.readRawPointer = _chunkKXWOF6H4cjs.readRawPointer; exports.utils = _chunkIBMXNAOTcjs.utils;
138
+ exports.AnyPointerList = _chunkIBMXNAOTcjs.AnyPointerList; exports.BoolList = _chunkIBMXNAOTcjs.BoolList; exports.CapnpRPC = _chunkIBMXNAOTcjs.CapnpRPC; exports.CodeGeneratorContext = _chunkR2JXWA7Qcjs.CodeGeneratorContext; exports.CompositeList = _chunkKXWOF6H4cjs.CompositeList; exports.Conn = _chunkIBMXNAOTcjs.Conn; exports.Data = _chunkKXWOF6H4cjs.Data; exports.DataList = _chunkIBMXNAOTcjs.DataList; exports.Deferred = _chunkIBMXNAOTcjs.Deferred; exports.DeferredTransport = _chunkIBMXNAOTcjs.DeferredTransport; exports.ErrorClient = _chunkKXWOF6H4cjs.ErrorClient; exports.Float32List = _chunkIBMXNAOTcjs.Float32List; exports.Float64List = _chunkIBMXNAOTcjs.Float64List; exports.Int16List = _chunkIBMXNAOTcjs.Int16List; exports.Int32List = _chunkIBMXNAOTcjs.Int32List; exports.Int64List = _chunkIBMXNAOTcjs.Int64List; exports.Int8List = _chunkIBMXNAOTcjs.Int8List; exports.Interface = _chunkIBMXNAOTcjs.Interface; exports.InterfaceList = _chunkIBMXNAOTcjs.InterfaceList; exports.List = _chunkKXWOF6H4cjs.List; exports.ListElementSize = _chunkKXWOF6H4cjs.ListElementSize; exports.Message = _chunkKXWOF6H4cjs.Message; exports.MessageChannelTransport = _chunkIBMXNAOTcjs.MessageChannelTransport; exports.ObjectSize = _chunkKXWOF6H4cjs.ObjectSize; exports.Orphan = _chunkKXWOF6H4cjs.Orphan; exports.Pipeline = _chunkIBMXNAOTcjs.Pipeline; exports.Pointer = _chunkKXWOF6H4cjs.Pointer; exports.PointerList = _chunkIBMXNAOTcjs.PointerList; exports.PointerType = _chunkKXWOF6H4cjs.PointerType; exports.Registry = _chunkIBMXNAOTcjs.Registry; exports.Server = _chunkIBMXNAOTcjs.Server; exports.Struct = _chunkKXWOF6H4cjs.Struct; exports.Text = _chunkKXWOF6H4cjs.Text; exports.TextList = _chunkIBMXNAOTcjs.TextList; exports.Uint16List = _chunkIBMXNAOTcjs.Uint16List; exports.Uint32List = _chunkIBMXNAOTcjs.Uint32List; exports.Uint64List = _chunkIBMXNAOTcjs.Uint64List; exports.Uint8List = _chunkIBMXNAOTcjs.Uint8List; exports.Void = _chunkIBMXNAOTcjs.Void; exports.VoidList = _chunkIBMXNAOTcjs.VoidList; exports.answerPipelineClient = _chunkIBMXNAOTcjs.answerPipelineClient; exports.capnpc = _chunkI7MRPN6Icjs.capnpc; exports.clientFromResolution = _chunkIBMXNAOTcjs.clientFromResolution; exports.clientOrNull = _chunkKXWOF6H4cjs.clientOrNull; exports.compile = _chunkI7MRPN6Icjs.compile; exports.copyCall = _chunkIBMXNAOTcjs.copyCall; exports.getBitMask = _chunkKXWOF6H4cjs.getBitMask; exports.getFloat32Mask = _chunkKXWOF6H4cjs.getFloat32Mask; exports.getFloat64Mask = _chunkKXWOF6H4cjs.getFloat64Mask; exports.getInt16Mask = _chunkKXWOF6H4cjs.getInt16Mask; exports.getInt32Mask = _chunkKXWOF6H4cjs.getInt32Mask; exports.getInt64Mask = _chunkKXWOF6H4cjs.getInt64Mask; exports.getInt8Mask = _chunkKXWOF6H4cjs.getInt8Mask; exports.getUint16Mask = _chunkKXWOF6H4cjs.getUint16Mask; exports.getUint32Mask = _chunkKXWOF6H4cjs.getUint32Mask; exports.getUint64Mask = _chunkKXWOF6H4cjs.getUint64Mask; exports.getUint8Mask = _chunkKXWOF6H4cjs.getUint8Mask; exports.isDataCall = _chunkIBMXNAOTcjs.isDataCall; exports.isFuncCall = _chunkIBMXNAOTcjs.isFuncCall; exports.isSameClient = _chunkIBMXNAOTcjs.isSameClient; exports.placeParams = _chunkIBMXNAOTcjs.placeParams; exports.readRawPointer = _chunkKXWOF6H4cjs.readRawPointer; exports.utils = _chunkIBMXNAOTcjs.utils;
package/dist/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  capnpc,
3
3
  compile
4
- } from "./chunk-GWW6WBAL.js";
5
- import "./chunk-3IOIINHW.js";
4
+ } from "./chunk-SW7GJVYC.js";
5
+ import "./chunk-XU7T5EQG.js";
6
6
  import {
7
7
  AnyPointerList,
8
8
  BoolList,
package/dist/types.d.cts CHANGED
@@ -40,7 +40,7 @@ type CapnpcOptions = Omit<CapnpcCLIOptions, "tsconfig" | "schema"> & {
40
40
  tsconfig?: ParsedCommandLine;
41
41
  tsconfigPath: string;
42
42
  });
43
- type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts"> & {
43
+ type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts" | "schemas" | "tsconfigPath" | "output"> & Required<Pick<CapnpcOptions, "output">> & {
44
44
  schemas: string[];
45
45
  tsconfig: ParsedCommandLine;
46
46
  };
package/dist/types.d.ts CHANGED
@@ -40,7 +40,7 @@ type CapnpcOptions = Omit<CapnpcCLIOptions, "tsconfig" | "schema"> & {
40
40
  tsconfig?: ParsedCommandLine;
41
41
  tsconfigPath: string;
42
42
  });
43
- type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts"> & {
43
+ type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts" | "schemas" | "tsconfigPath" | "output"> & Required<Pick<CapnpcOptions, "output">> & {
44
44
  schemas: string[];
45
45
  tsconfig: ParsedCommandLine;
46
46
  };
package/dts/index.d.cts CHANGED
@@ -4118,7 +4118,7 @@ export type CapnpcOptions = Omit<CapnpcCLIOptions, "tsconfig" | "schema"> & {
4118
4118
  tsconfig?: ParsedCommandLine;
4119
4119
  tsconfigPath: string;
4120
4120
  });
4121
- export type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts"> & {
4121
+ export type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts" | "schemas" | "tsconfigPath" | "output"> & Required<Pick<CapnpcOptions, "output">> & {
4122
4122
  schemas: string[];
4123
4123
  tsconfig: ParsedCommandLine;
4124
4124
  };
package/dts/index.d.ts CHANGED
@@ -4118,7 +4118,7 @@ export type CapnpcOptions = Omit<CapnpcCLIOptions, "tsconfig" | "schema"> & {
4118
4118
  tsconfig?: ParsedCommandLine;
4119
4119
  tsconfigPath: string;
4120
4120
  });
4121
- export type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts"> & {
4121
+ export type CapnpcResolvedOptions = Omit<CapnpcOptions, "noTs" | "noDts" | "schemas" | "tsconfigPath" | "output"> & Required<Pick<CapnpcOptions, "output">> & {
4122
4122
  schemas: string[];
4123
4123
  tsconfig: ParsedCommandLine;
4124
4124
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stryke/capnp",
3
- "version": "0.10.2",
3
+ "version": "0.10.3",
4
4
  "type": "module",
5
5
  "description": "A package to assist in running the Cap'n Proto compiler and creating Cap'n Proto serialization protocol schemas.",
6
6
  "repository": {
@@ -148,5 +148,5 @@
148
148
  "tsx": "^4.20.1"
149
149
  },
150
150
  "publishConfig": { "access": "public" },
151
- "gitHead": "bd1c18c69a24e82c1b126b1e5de36008bbac52d9"
151
+ "gitHead": "f54ef4923dcd93cc234959b706369f90f0f6dc24"
152
152
  }
@@ -4070,6 +4070,17 @@ var ConnWeakRefRegistry = globalThis.FinalizationRegistry ? new FinalizationRegi
4070
4070
 
4071
4071
  // src/compile.ts
4072
4072
  var _console = require('@storm-software/config-tools/logger/console');
4073
+
4074
+ // ../path/src/exists.ts
4075
+ var _fs = require('fs');
4076
+ var _promises = require('fs/promises');
4077
+
4078
+ // ../fs/src/helpers.ts
4079
+ var _nanotar = require('nanotar');
4080
+
4081
+
4082
+
4083
+ // src/compile.ts
4073
4084
  var _defu = require('defu'); var _defu2 = _interopRequireDefault(_defu);
4074
4085
  var _buffer = require('buffer');
4075
4086
  var _child_process = require('child_process');
@@ -4632,14 +4643,10 @@ StormJSON.instance.registerCustom({
4632
4643
  }, "Bytes");
4633
4644
 
4634
4645
  // ../fs/src/read-file.ts
4635
- var _fs = require('fs');
4636
- var _promises = require('fs/promises');
4637
-
4638
- // ../path/src/is-file.ts
4639
4646
 
4640
4647
 
4641
- // ../path/src/exists.ts
4642
4648
 
4649
+ // ../path/src/is-file.ts
4643
4650
 
4644
4651
 
4645
4652
  // ../path/src/file-path-fns.ts
@@ -4652,11 +4659,6 @@ var _configtools = require('@storm-software/config-tools');
4652
4659
 
4653
4660
 
4654
4661
 
4655
- // ../fs/src/helpers.ts
4656
- var _nanotar = require('nanotar');
4657
-
4658
-
4659
-
4660
4662
  // ../fs/src/list-files.ts
4661
4663
 
4662
4664
  var _glob = require('glob');
@@ -4070,6 +4070,17 @@ var ConnWeakRefRegistry = globalThis.FinalizationRegistry ? new FinalizationRegi
4070
4070
 
4071
4071
  // src/compile.ts
4072
4072
  import { writeWarning as writeWarning2 } from "@storm-software/config-tools/logger/console";
4073
+
4074
+ // ../path/src/exists.ts
4075
+ import { existsSync as existsSyncFs } from "node:fs";
4076
+ import { access, constants } from "node:fs/promises";
4077
+
4078
+ // ../fs/src/helpers.ts
4079
+ import { parseTar, parseTarGzip } from "nanotar";
4080
+ import { createWriteStream, mkdirSync, rmSync } from "node:fs";
4081
+ import { mkdir, readFile, rm } from "node:fs/promises";
4082
+
4083
+ // src/compile.ts
4073
4084
  import defu2 from "defu";
4074
4085
  import { Buffer as Buffer2 } from "node:buffer";
4075
4086
  import { exec } from "node:child_process";
@@ -4632,16 +4643,12 @@ StormJSON.instance.registerCustom({
4632
4643
  }, "Bytes");
4633
4644
 
4634
4645
  // ../fs/src/read-file.ts
4635
- import { existsSync, readFileSync as readFileSyncFs } from "node:fs";
4646
+ import { existsSync as existsSync2, readFileSync as readFileSyncFs } from "node:fs";
4636
4647
  import { readFile as readFileFs } from "node:fs/promises";
4637
4648
 
4638
4649
  // ../path/src/is-file.ts
4639
4650
  import { lstatSync, statSync } from "node:fs";
4640
4651
 
4641
- // ../path/src/exists.ts
4642
- import { existsSync as existsSyncFs } from "node:fs";
4643
- import { access, constants } from "node:fs/promises";
4644
-
4645
4652
  // ../path/src/file-path-fns.ts
4646
4653
  import { relative } from "node:path";
4647
4654
 
@@ -4652,11 +4659,6 @@ import { findWorkspaceRootSafe } from "@storm-software/config-tools";
4652
4659
  import { writeFileSync as writeFileSyncFs } from "node:fs";
4653
4660
  import { writeFile as writeFileFs } from "node:fs/promises";
4654
4661
 
4655
- // ../fs/src/helpers.ts
4656
- import { parseTar, parseTarGzip } from "nanotar";
4657
- import { createWriteStream, mkdirSync, rmSync } from "node:fs";
4658
- import { mkdir, readFile, rm } from "node:fs/promises";
4659
-
4660
4662
  // ../fs/src/list-files.ts
4661
4663
  import defu from "defu";
4662
4664
  import { glob } from "glob";
@@ -6,27 +6,27 @@
6
6
 
7
7
 
8
8
 
9
- var _chunkBM2HWFSDcjs = require('./chunk-BM2HWFSD.cjs');
9
+ var _chunkERVRKJ2Scjs = require('./chunk-ERVRKJ2S.cjs');
10
10
 
11
11
 
12
12
  var _chunkUSNT2KNTcjs = require('./chunk-USNT2KNT.cjs');
13
13
 
14
14
  // schemas/persistent.ts
15
15
  var _capnpFileId = BigInt("0xb8630836983feed7");
16
- var Persistent_SaveParams = (_class = class extends _chunkBM2HWFSDcjs.Struct {
16
+ var Persistent_SaveParams = (_class = class extends _chunkERVRKJ2Scjs.Struct {
17
17
  static {
18
18
  _chunkUSNT2KNTcjs.__name.call(void 0, this, "Persistent_SaveParams");
19
19
  }
20
20
  static __initStatic() {this._capnp = {
21
21
  displayName: "SaveParams",
22
22
  id: "f76fba59183073a5",
23
- size: new (0, _chunkBM2HWFSDcjs.ObjectSize)(0, 1)
23
+ size: new (0, _chunkERVRKJ2Scjs.ObjectSize)(0, 1)
24
24
  }}
25
25
  _adoptSealFor(value) {
26
- _chunkBM2HWFSDcjs.utils.adopt(value, _chunkBM2HWFSDcjs.utils.getPointer(0, this));
26
+ _chunkERVRKJ2Scjs.utils.adopt(value, _chunkERVRKJ2Scjs.utils.getPointer(0, this));
27
27
  }
28
28
  _disownSealFor() {
29
- return _chunkBM2HWFSDcjs.utils.disown(this.sealFor);
29
+ return _chunkERVRKJ2Scjs.utils.disown(this.sealFor);
30
30
  }
31
31
  /**
32
32
  * Seal the SturdyRef so that it can only be restored by the specified Owner. This is meant
@@ -38,41 +38,41 @@ var Persistent_SaveParams = (_class = class extends _chunkBM2HWFSDcjs.Struct {
38
38
  *
39
39
  */
40
40
  get sealFor() {
41
- return _chunkBM2HWFSDcjs.utils.getPointer(0, this);
41
+ return _chunkERVRKJ2Scjs.utils.getPointer(0, this);
42
42
  }
43
43
  _hasSealFor() {
44
- return !_chunkBM2HWFSDcjs.utils.isNull(_chunkBM2HWFSDcjs.utils.getPointer(0, this));
44
+ return !_chunkERVRKJ2Scjs.utils.isNull(_chunkERVRKJ2Scjs.utils.getPointer(0, this));
45
45
  }
46
46
  set sealFor(value) {
47
- _chunkBM2HWFSDcjs.utils.copyFrom(value, _chunkBM2HWFSDcjs.utils.getPointer(0, this));
47
+ _chunkERVRKJ2Scjs.utils.copyFrom(value, _chunkERVRKJ2Scjs.utils.getPointer(0, this));
48
48
  }
49
49
  toString() {
50
50
  return "Persistent_SaveParams_" + super.toString();
51
51
  }
52
52
  }, _class.__initStatic(), _class);
53
- var Persistent_SaveResults = (_class2 = class extends _chunkBM2HWFSDcjs.Struct {
53
+ var Persistent_SaveResults = (_class2 = class extends _chunkERVRKJ2Scjs.Struct {
54
54
  static {
55
55
  _chunkUSNT2KNTcjs.__name.call(void 0, this, "Persistent_SaveResults");
56
56
  }
57
57
  static __initStatic2() {this._capnp = {
58
58
  displayName: "SaveResults",
59
59
  id: "b76848c18c40efbf",
60
- size: new (0, _chunkBM2HWFSDcjs.ObjectSize)(0, 1)
60
+ size: new (0, _chunkERVRKJ2Scjs.ObjectSize)(0, 1)
61
61
  }}
62
62
  _adoptSturdyRef(value) {
63
- _chunkBM2HWFSDcjs.utils.adopt(value, _chunkBM2HWFSDcjs.utils.getPointer(0, this));
63
+ _chunkERVRKJ2Scjs.utils.adopt(value, _chunkERVRKJ2Scjs.utils.getPointer(0, this));
64
64
  }
65
65
  _disownSturdyRef() {
66
- return _chunkBM2HWFSDcjs.utils.disown(this.sturdyRef);
66
+ return _chunkERVRKJ2Scjs.utils.disown(this.sturdyRef);
67
67
  }
68
68
  get sturdyRef() {
69
- return _chunkBM2HWFSDcjs.utils.getPointer(0, this);
69
+ return _chunkERVRKJ2Scjs.utils.getPointer(0, this);
70
70
  }
71
71
  _hasSturdyRef() {
72
- return !_chunkBM2HWFSDcjs.utils.isNull(_chunkBM2HWFSDcjs.utils.getPointer(0, this));
72
+ return !_chunkERVRKJ2Scjs.utils.isNull(_chunkERVRKJ2Scjs.utils.getPointer(0, this));
73
73
  }
74
74
  set sturdyRef(value) {
75
- _chunkBM2HWFSDcjs.utils.copyFrom(value, _chunkBM2HWFSDcjs.utils.getPointer(0, this));
75
+ _chunkERVRKJ2Scjs.utils.copyFrom(value, _chunkERVRKJ2Scjs.utils.getPointer(0, this));
76
76
  }
77
77
  toString() {
78
78
  return "Persistent_SaveResults_" + super.toString();
@@ -120,12 +120,12 @@ var Persistent$Client = (_class3 = class _Persistent$Client {
120
120
  method: _Persistent$Client.methods[0],
121
121
  paramsFunc
122
122
  });
123
- const pipeline = new (0, _chunkBM2HWFSDcjs.Pipeline)(Persistent_SaveResults, answer);
123
+ const pipeline = new (0, _chunkERVRKJ2Scjs.Pipeline)(Persistent_SaveResults, answer);
124
124
  return new Persistent_SaveResults$Promise(pipeline);
125
125
  }
126
126
  }, _class3.__initStatic3(), _class3.__initStatic4(), _class3);
127
- _chunkBM2HWFSDcjs.Registry.register(Persistent$Client.interfaceId, Persistent$Client);
128
- var Persistent$Server = class extends _chunkBM2HWFSDcjs.Server {
127
+ _chunkERVRKJ2Scjs.Registry.register(Persistent$Client.interfaceId, Persistent$Client);
128
+ var Persistent$Server = class extends _chunkERVRKJ2Scjs.Server {
129
129
  static {
130
130
  _chunkUSNT2KNTcjs.__name.call(void 0, this, "Persistent$Server");
131
131
  }
@@ -143,7 +143,7 @@ var Persistent$Server = class extends _chunkBM2HWFSDcjs.Server {
143
143
  return new Persistent$Client(this);
144
144
  }
145
145
  };
146
- var Persistent = (_class4 = class extends _chunkBM2HWFSDcjs.Interface {
146
+ var Persistent = (_class4 = class extends _chunkERVRKJ2Scjs.Interface {
147
147
  static {
148
148
  _chunkUSNT2KNTcjs.__name.call(void 0, this, "Persistent");
149
149
  }
@@ -154,7 +154,7 @@ var Persistent = (_class4 = class extends _chunkBM2HWFSDcjs.Interface {
154
154
  static __initStatic9() {this._capnp = {
155
155
  displayName: "Persistent",
156
156
  id: "c8cb212fcd9f5691",
157
- size: new (0, _chunkBM2HWFSDcjs.ObjectSize)(0, 0)
157
+ size: new (0, _chunkERVRKJ2Scjs.ObjectSize)(0, 0)
158
158
  }}
159
159
  toString() {
160
160
  return "Persistent_" + super.toString();
@@ -6,7 +6,7 @@ import {
6
6
  Server,
7
7
  Struct,
8
8
  utils
9
- } from "./chunk-TAKPBFYZ.js";
9
+ } from "./chunk-OKQBZPI3.js";
10
10
  import {
11
11
  __name
12
12
  } from "./chunk-SHUYVCID.js";