@milaboratories/pl-deployments 2.15.17 → 2.15.19

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 (104) hide show
  1. package/dist/_virtual/_rolldown/runtime.cjs +29 -0
  2. package/dist/common/os_and_arch.cjs +22 -28
  3. package/dist/common/os_and_arch.cjs.map +1 -1
  4. package/dist/common/os_and_arch.js +23 -26
  5. package/dist/common/os_and_arch.js.map +1 -1
  6. package/dist/common/pl_binary.cjs +35 -33
  7. package/dist/common/pl_binary.cjs.map +1 -1
  8. package/dist/common/pl_binary.d.ts +13 -18
  9. package/dist/common/pl_binary.js +33 -31
  10. package/dist/common/pl_binary.js.map +1 -1
  11. package/dist/common/pl_binary_download.cjs +143 -155
  12. package/dist/common/pl_binary_download.cjs.map +1 -1
  13. package/dist/common/pl_binary_download.d.ts +15 -48
  14. package/dist/common/pl_binary_download.js +138 -133
  15. package/dist/common/pl_binary_download.js.map +1 -1
  16. package/dist/common/pl_version.cjs +5 -6
  17. package/dist/common/pl_version.cjs.map +1 -1
  18. package/dist/common/pl_version.d.ts +4 -1
  19. package/dist/common/pl_version.js +5 -4
  20. package/dist/common/pl_version.js.map +1 -1
  21. package/dist/index.cjs +21 -25
  22. package/dist/index.d.ts +6 -6
  23. package/dist/index.js +7 -6
  24. package/dist/local/pid.cjs +14 -13
  25. package/dist/local/pid.cjs.map +1 -1
  26. package/dist/local/pid.js +11 -11
  27. package/dist/local/pid.js.map +1 -1
  28. package/dist/local/pl.cjs +194 -223
  29. package/dist/local/pl.cjs.map +1 -1
  30. package/dist/local/pl.d.ts +65 -65
  31. package/dist/local/pl.js +190 -202
  32. package/dist/local/pl.js.map +1 -1
  33. package/dist/local/process.cjs +37 -59
  34. package/dist/local/process.cjs.map +1 -1
  35. package/dist/local/process.d.ts +10 -10
  36. package/dist/local/process.js +36 -57
  37. package/dist/local/process.js.map +1 -1
  38. package/dist/local/trace.cjs +14 -17
  39. package/dist/local/trace.cjs.map +1 -1
  40. package/dist/local/trace.d.ts +6 -7
  41. package/dist/local/trace.js +15 -15
  42. package/dist/local/trace.js.map +1 -1
  43. package/dist/package.cjs +12 -0
  44. package/dist/package.cjs.map +1 -0
  45. package/dist/package.js +6 -0
  46. package/dist/package.js.map +1 -0
  47. package/dist/ssh/connection_info.cjs +36 -53
  48. package/dist/ssh/connection_info.cjs.map +1 -1
  49. package/dist/ssh/connection_info.d.ts +691 -713
  50. package/dist/ssh/connection_info.js +35 -51
  51. package/dist/ssh/connection_info.js.map +1 -1
  52. package/dist/ssh/pl.cjs +551 -638
  53. package/dist/ssh/pl.cjs.map +1 -1
  54. package/dist/ssh/pl.d.ts +120 -117
  55. package/dist/ssh/pl.js +548 -636
  56. package/dist/ssh/pl.js.map +1 -1
  57. package/dist/ssh/pl_paths.cjs +22 -24
  58. package/dist/ssh/pl_paths.cjs.map +1 -1
  59. package/dist/ssh/pl_paths.js +21 -19
  60. package/dist/ssh/pl_paths.js.map +1 -1
  61. package/dist/ssh/ssh.cjs +554 -618
  62. package/dist/ssh/ssh.cjs.map +1 -1
  63. package/dist/ssh/ssh.d.ts +139 -136
  64. package/dist/ssh/ssh.js +548 -616
  65. package/dist/ssh/ssh.js.map +1 -1
  66. package/dist/ssh/ssh_errors.cjs +45 -60
  67. package/dist/ssh/ssh_errors.cjs.map +1 -1
  68. package/dist/ssh/ssh_errors.js +45 -58
  69. package/dist/ssh/ssh_errors.js.map +1 -1
  70. package/dist/ssh/supervisord.cjs +50 -68
  71. package/dist/ssh/supervisord.cjs.map +1 -1
  72. package/dist/ssh/supervisord.d.ts +11 -21
  73. package/dist/ssh/supervisord.js +50 -66
  74. package/dist/ssh/supervisord.js.map +1 -1
  75. package/package.json +10 -10
  76. package/dist/common/os_and_arch.d.ts +0 -9
  77. package/dist/common/os_and_arch.d.ts.map +0 -1
  78. package/dist/common/pl_binary.d.ts.map +0 -1
  79. package/dist/common/pl_binary_download.d.ts.map +0 -1
  80. package/dist/common/pl_version.d.ts.map +0 -1
  81. package/dist/index.cjs.map +0 -1
  82. package/dist/index.d.ts.map +0 -1
  83. package/dist/index.js.map +0 -1
  84. package/dist/local/options.d.ts +0 -31
  85. package/dist/local/options.d.ts.map +0 -1
  86. package/dist/local/pid.d.ts +0 -4
  87. package/dist/local/pid.d.ts.map +0 -1
  88. package/dist/local/pl.d.ts.map +0 -1
  89. package/dist/local/process.d.ts.map +0 -1
  90. package/dist/local/trace.d.ts.map +0 -1
  91. package/dist/package.json.cjs +0 -8
  92. package/dist/package.json.cjs.map +0 -1
  93. package/dist/package.json.js +0 -6
  94. package/dist/package.json.js.map +0 -1
  95. package/dist/ssh/__tests__/common-utils.d.ts +0 -12
  96. package/dist/ssh/__tests__/common-utils.d.ts.map +0 -1
  97. package/dist/ssh/connection_info.d.ts.map +0 -1
  98. package/dist/ssh/pl.d.ts.map +0 -1
  99. package/dist/ssh/pl_paths.d.ts +0 -20
  100. package/dist/ssh/pl_paths.d.ts.map +0 -1
  101. package/dist/ssh/ssh.d.ts.map +0 -1
  102. package/dist/ssh/ssh_errors.d.ts +0 -29
  103. package/dist/ssh/ssh_errors.d.ts.map +0 -1
  104. package/dist/ssh/supervisord.d.ts.map +0 -1
@@ -0,0 +1,29 @@
1
+ //#region \0rolldown/runtime.js
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __copyProps = (to, from, except, desc) => {
9
+ if (from && typeof from === "object" || typeof from === "function") {
10
+ for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
11
+ key = keys[i];
12
+ if (!__hasOwnProp.call(to, key) && key !== except) {
13
+ __defProp(to, key, {
14
+ get: ((k) => from[k]).bind(null, key),
15
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
16
+ });
17
+ }
18
+ }
19
+ }
20
+ return to;
21
+ };
22
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
23
+ value: mod,
24
+ enumerable: true
25
+ }) : target, mod));
26
+
27
+ //#endregion
28
+
29
+ exports.__toESM = __toESM;
@@ -1,39 +1,33 @@
1
- 'use strict';
2
1
 
3
- const OSes = ["linux", "macos", "windows"];
2
+ //#region src/common/os_and_arch.ts
3
+ const OSes = [
4
+ "linux",
5
+ "macos",
6
+ "windows"
7
+ ];
4
8
  /** @param osName - should be the thing returned from either {@link os.platform())} or `uname -s` */
5
9
  function newOs(osName) {
6
- switch (osName.toLowerCase()) {
7
- case "darwin":
8
- return "macos";
9
- case "linux":
10
- return "linux";
11
- case "win32":
12
- return "windows";
13
- default:
14
- throw new Error(`operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` +
15
- JSON.stringify(OSes));
16
- }
10
+ switch (osName.toLowerCase()) {
11
+ case "darwin": return "macos";
12
+ case "linux": return "linux";
13
+ case "win32": return "windows";
14
+ default: throw new Error(`operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` + JSON.stringify(OSes));
15
+ }
17
16
  }
18
17
  const Arches = ["amd64", "arm64"];
19
18
  /** @param arch - should be the thing returned from either {@link os.arch())} or `uname -m` */
20
19
  function newArch(arch) {
21
- switch (arch) {
22
- case "aarch64":
23
- case "aarch64_be":
24
- case "arm64":
25
- return "arm64";
26
- case "x86_64":
27
- case "x64":
28
- return "amd64";
29
- default:
30
- throw new Error(`processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` +
31
- JSON.stringify(Arches));
32
- }
20
+ switch (arch) {
21
+ case "aarch64":
22
+ case "aarch64_be":
23
+ case "arm64": return "arm64";
24
+ case "x86_64":
25
+ case "x64": return "amd64";
26
+ default: throw new Error(`processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` + JSON.stringify(Arches));
27
+ }
33
28
  }
34
29
 
35
- exports.Arches = Arches;
36
- exports.OSes = OSes;
30
+ //#endregion
37
31
  exports.newArch = newArch;
38
32
  exports.newOs = newOs;
39
- //# sourceMappingURL=os_and_arch.cjs.map
33
+ //# sourceMappingURL=os_and_arch.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"os_and_arch.cjs","sources":["../../src/common/os_and_arch.ts"],"sourcesContent":["export const OSes = [\"linux\", \"macos\", \"windows\"] as const;\nexport type OSType = (typeof OSes)[number];\n\n/** @param osName - should be the thing returned from either {@link os.platform())} or `uname -s` */\nexport function newOs(osName: string): OSType {\n switch (osName.toLowerCase()) {\n case \"darwin\":\n return \"macos\";\n case \"linux\":\n return \"linux\";\n case \"win32\":\n return \"windows\";\n default:\n throw new Error(\n `operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` +\n JSON.stringify(OSes),\n );\n }\n}\n\nexport const Arches = [\"amd64\", \"arm64\"] as const;\nexport type ArchType = (typeof Arches)[number];\n\n/** @param arch - should be the thing returned from either {@link os.arch())} or `uname -m` */\nexport function newArch(arch: string): ArchType {\n switch (arch) {\n case \"aarch64\":\n case \"aarch64_be\":\n case \"arm64\":\n return \"arm64\";\n\n case \"x86_64\":\n case \"x64\":\n return \"amd64\";\n\n default:\n throw new Error(\n `processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` +\n JSON.stringify(Arches),\n );\n }\n}\n"],"names":[],"mappings":";;AAAO,MAAM,IAAI,GAAG,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS;AAGhD;AACM,SAAU,KAAK,CAAC,MAAc,EAAA;AAClC,IAAA,QAAQ,MAAM,CAAC,WAAW,EAAE;AAC1B,QAAA,KAAK,QAAQ;AACX,YAAA,OAAO,OAAO;AAChB,QAAA,KAAK,OAAO;AACV,YAAA,OAAO,OAAO;AAChB,QAAA,KAAK,OAAO;AACV,YAAA,OAAO,SAAS;AAClB,QAAA;AACE,YAAA,MAAM,IAAI,KAAK,CACb,CAAA,kBAAA,EAAqB,MAAM,CAAA,iFAAA,CAAmF;AAC5G,gBAAA,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CACvB;;AAEP;MAEa,MAAM,GAAG,CAAC,OAAO,EAAE,OAAO;AAGvC;AACM,SAAU,OAAO,CAAC,IAAY,EAAA;IAClC,QAAQ,IAAI;AACV,QAAA,KAAK,SAAS;AACd,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,OAAO;AACV,YAAA,OAAO,OAAO;AAEhB,QAAA,KAAK,QAAQ;AACb,QAAA,KAAK,KAAK;AACR,YAAA,OAAO,OAAO;AAEhB,QAAA;AACE,YAAA,MAAM,IAAI,KAAK,CACb,CAAA,wBAAA,EAA2B,IAAI,CAAA,0FAAA,CAA4F;AACzH,gBAAA,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CACzB;;AAEP;;;;;;;"}
1
+ {"version":3,"file":"os_and_arch.cjs","names":[],"sources":["../../src/common/os_and_arch.ts"],"sourcesContent":["export const OSes = [\"linux\", \"macos\", \"windows\"] as const;\nexport type OSType = (typeof OSes)[number];\n\n/** @param osName - should be the thing returned from either {@link os.platform())} or `uname -s` */\nexport function newOs(osName: string): OSType {\n switch (osName.toLowerCase()) {\n case \"darwin\":\n return \"macos\";\n case \"linux\":\n return \"linux\";\n case \"win32\":\n return \"windows\";\n default:\n throw new Error(\n `operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` +\n JSON.stringify(OSes),\n );\n }\n}\n\nexport const Arches = [\"amd64\", \"arm64\"] as const;\nexport type ArchType = (typeof Arches)[number];\n\n/** @param arch - should be the thing returned from either {@link os.arch())} or `uname -m` */\nexport function newArch(arch: string): ArchType {\n switch (arch) {\n case \"aarch64\":\n case \"aarch64_be\":\n case \"arm64\":\n return \"arm64\";\n\n case \"x86_64\":\n case \"x64\":\n return \"amd64\";\n\n default:\n throw new Error(\n `processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` +\n JSON.stringify(Arches),\n );\n }\n}\n"],"mappings":";;AAAA,MAAa,OAAO;CAAC;CAAS;CAAS;CAAU;;AAIjD,SAAgB,MAAM,QAAwB;AAC5C,SAAQ,OAAO,aAAa,EAA5B;EACE,KAAK,SACH,QAAO;EACT,KAAK,QACH,QAAO;EACT,KAAK,QACH,QAAO;EACT,QACE,OAAM,IAAI,MACR,qBAAqB,OAAO,qFAC1B,KAAK,UAAU,KAAK,CACvB;;;AAIP,MAAa,SAAS,CAAC,SAAS,QAAQ;;AAIxC,SAAgB,QAAQ,MAAwB;AAC9C,SAAQ,MAAR;EACE,KAAK;EACL,KAAK;EACL,KAAK,QACH,QAAO;EAET,KAAK;EACL,KAAK,MACH,QAAO;EAET,QACE,OAAM,IAAI,MACR,2BAA2B,KAAK,8FAC9B,KAAK,UAAU,OAAO,CACzB"}
@@ -1,34 +1,31 @@
1
- const OSes = ["linux", "macos", "windows"];
1
+ //#region src/common/os_and_arch.ts
2
+ const OSes = [
3
+ "linux",
4
+ "macos",
5
+ "windows"
6
+ ];
2
7
  /** @param osName - should be the thing returned from either {@link os.platform())} or `uname -s` */
3
8
  function newOs(osName) {
4
- switch (osName.toLowerCase()) {
5
- case "darwin":
6
- return "macos";
7
- case "linux":
8
- return "linux";
9
- case "win32":
10
- return "windows";
11
- default:
12
- throw new Error(`operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` +
13
- JSON.stringify(OSes));
14
- }
9
+ switch (osName.toLowerCase()) {
10
+ case "darwin": return "macos";
11
+ case "linux": return "linux";
12
+ case "win32": return "windows";
13
+ default: throw new Error(`operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` + JSON.stringify(OSes));
14
+ }
15
15
  }
16
16
  const Arches = ["amd64", "arm64"];
17
17
  /** @param arch - should be the thing returned from either {@link os.arch())} or `uname -m` */
18
18
  function newArch(arch) {
19
- switch (arch) {
20
- case "aarch64":
21
- case "aarch64_be":
22
- case "arm64":
23
- return "arm64";
24
- case "x86_64":
25
- case "x64":
26
- return "amd64";
27
- default:
28
- throw new Error(`processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` +
29
- JSON.stringify(Arches));
30
- }
19
+ switch (arch) {
20
+ case "aarch64":
21
+ case "aarch64_be":
22
+ case "arm64": return "arm64";
23
+ case "x86_64":
24
+ case "x64": return "amd64";
25
+ default: throw new Error(`processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` + JSON.stringify(Arches));
26
+ }
31
27
  }
32
28
 
33
- export { Arches, OSes, newArch, newOs };
34
- //# sourceMappingURL=os_and_arch.js.map
29
+ //#endregion
30
+ export { newArch, newOs };
31
+ //# sourceMappingURL=os_and_arch.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"os_and_arch.js","sources":["../../src/common/os_and_arch.ts"],"sourcesContent":["export const OSes = [\"linux\", \"macos\", \"windows\"] as const;\nexport type OSType = (typeof OSes)[number];\n\n/** @param osName - should be the thing returned from either {@link os.platform())} or `uname -s` */\nexport function newOs(osName: string): OSType {\n switch (osName.toLowerCase()) {\n case \"darwin\":\n return \"macos\";\n case \"linux\":\n return \"linux\";\n case \"win32\":\n return \"windows\";\n default:\n throw new Error(\n `operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` +\n JSON.stringify(OSes),\n );\n }\n}\n\nexport const Arches = [\"amd64\", \"arm64\"] as const;\nexport type ArchType = (typeof Arches)[number];\n\n/** @param arch - should be the thing returned from either {@link os.arch())} or `uname -m` */\nexport function newArch(arch: string): ArchType {\n switch (arch) {\n case \"aarch64\":\n case \"aarch64_be\":\n case \"arm64\":\n return \"arm64\";\n\n case \"x86_64\":\n case \"x64\":\n return \"amd64\";\n\n default:\n throw new Error(\n `processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` +\n JSON.stringify(Arches),\n );\n }\n}\n"],"names":[],"mappings":"AAAO,MAAM,IAAI,GAAG,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS;AAGhD;AACM,SAAU,KAAK,CAAC,MAAc,EAAA;AAClC,IAAA,QAAQ,MAAM,CAAC,WAAW,EAAE;AAC1B,QAAA,KAAK,QAAQ;AACX,YAAA,OAAO,OAAO;AAChB,QAAA,KAAK,OAAO;AACV,YAAA,OAAO,OAAO;AAChB,QAAA,KAAK,OAAO;AACV,YAAA,OAAO,SAAS;AAClB,QAAA;AACE,YAAA,MAAM,IAAI,KAAK,CACb,CAAA,kBAAA,EAAqB,MAAM,CAAA,iFAAA,CAAmF;AAC5G,gBAAA,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CACvB;;AAEP;MAEa,MAAM,GAAG,CAAC,OAAO,EAAE,OAAO;AAGvC;AACM,SAAU,OAAO,CAAC,IAAY,EAAA;IAClC,QAAQ,IAAI;AACV,QAAA,KAAK,SAAS;AACd,QAAA,KAAK,YAAY;AACjB,QAAA,KAAK,OAAO;AACV,YAAA,OAAO,OAAO;AAEhB,QAAA,KAAK,QAAQ;AACb,QAAA,KAAK,KAAK;AACR,YAAA,OAAO,OAAO;AAEhB,QAAA;AACE,YAAA,MAAM,IAAI,KAAK,CACb,CAAA,wBAAA,EAA2B,IAAI,CAAA,0FAAA,CAA4F;AACzH,gBAAA,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CACzB;;AAEP;;;;"}
1
+ {"version":3,"file":"os_and_arch.js","names":[],"sources":["../../src/common/os_and_arch.ts"],"sourcesContent":["export const OSes = [\"linux\", \"macos\", \"windows\"] as const;\nexport type OSType = (typeof OSes)[number];\n\n/** @param osName - should be the thing returned from either {@link os.platform())} or `uname -s` */\nexport function newOs(osName: string): OSType {\n switch (osName.toLowerCase()) {\n case \"darwin\":\n return \"macos\";\n case \"linux\":\n return \"linux\";\n case \"win32\":\n return \"windows\";\n default:\n throw new Error(\n `operating system '${osName}' is not currently supported by Platforma ecosystem. The list of OSes supported: ` +\n JSON.stringify(OSes),\n );\n }\n}\n\nexport const Arches = [\"amd64\", \"arm64\"] as const;\nexport type ArchType = (typeof Arches)[number];\n\n/** @param arch - should be the thing returned from either {@link os.arch())} or `uname -m` */\nexport function newArch(arch: string): ArchType {\n switch (arch) {\n case \"aarch64\":\n case \"aarch64_be\":\n case \"arm64\":\n return \"arm64\";\n\n case \"x86_64\":\n case \"x64\":\n return \"amd64\";\n\n default:\n throw new Error(\n `processor architecture '${arch}' is not currently supported by Platforma ecosystem. The list of architectures supported: ` +\n JSON.stringify(Arches),\n );\n }\n}\n"],"mappings":";AAAA,MAAa,OAAO;CAAC;CAAS;CAAS;CAAU;;AAIjD,SAAgB,MAAM,QAAwB;AAC5C,SAAQ,OAAO,aAAa,EAA5B;EACE,KAAK,SACH,QAAO;EACT,KAAK,QACH,QAAO;EACT,KAAK,QACH,QAAO;EACT,QACE,OAAM,IAAI,MACR,qBAAqB,OAAO,qFAC1B,KAAK,UAAU,KAAK,CACvB;;;AAIP,MAAa,SAAS,CAAC,SAAS,QAAQ;;AAIxC,SAAgB,QAAQ,MAAwB;AAC9C,SAAQ,MAAR;EACE,KAAK;EACL,KAAK;EACL,KAAK,QACH,QAAO;EAET,KAAK;EACL,KAAK,MACH,QAAO;EAET,QACE,OAAM,IAAI,MACR,2BAA2B,KAAK,8FAC9B,KAAK,UAAU,OAAO,CACzB"}
@@ -1,42 +1,44 @@
1
- 'use strict';
2
-
3
- var tsHelpers = require('@milaboratories/ts-helpers');
4
- var pl_binary_download = require('./pl_binary_download.cjs');
5
- var pl_version = require('./pl_version.cjs');
6
- var os = require('node:os');
7
- var upath = require('upath');
8
- var os_and_arch = require('./os_and_arch.cjs');
1
+ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
2
+ const require_os_and_arch = require('./os_and_arch.cjs');
3
+ const require_pl_binary_download = require('./pl_binary_download.cjs');
4
+ const require_pl_version = require('./pl_version.cjs');
5
+ let _milaboratories_ts_helpers = require("@milaboratories/ts-helpers");
6
+ let upath = require("upath");
7
+ upath = require_runtime.__toESM(upath);
8
+ let node_os = require("node:os");
9
+ node_os = require_runtime.__toESM(node_os);
9
10
 
11
+ //#region src/common/pl_binary.ts
10
12
  function newDefaultPlBinarySource() {
11
- return { type: "Download", version: pl_version.getDefaultPlVersion() };
13
+ return {
14
+ type: "Download",
15
+ version: require_pl_version.getDefaultPlVersion()
16
+ };
12
17
  }
13
- async function resolveLocalPlBinaryPath({ logger, downloadDir, src, dispatcher, }) {
14
- switch (src.type) {
15
- case "Download":
16
- // eslint-disable-next-line no-case-declarations
17
- const ops = await pl_binary_download.downloadBinary({
18
- logger,
19
- baseDir: downloadDir,
20
- softwareName: "pl",
21
- archiveName: `pl-${src.version}`,
22
- arch: os.arch(),
23
- platform: os.platform(),
24
- dispatcher,
25
- });
26
- return upath.join(ops.baseName, "binaries", osToBinaryName[os_and_arch.newOs(os.platform())]);
27
- case "Local":
28
- return src.path;
29
- default:
30
- tsHelpers.assertNever(src);
31
- }
18
+ async function resolveLocalPlBinaryPath({ logger, downloadDir, src, dispatcher }) {
19
+ switch (src.type) {
20
+ case "Download":
21
+ const ops = await require_pl_binary_download.downloadBinary({
22
+ logger,
23
+ baseDir: downloadDir,
24
+ softwareName: "pl",
25
+ archiveName: `pl-${src.version}`,
26
+ arch: node_os.default.arch(),
27
+ platform: node_os.default.platform(),
28
+ dispatcher
29
+ });
30
+ return upath.default.join(ops.baseName, "binaries", osToBinaryName[require_os_and_arch.newOs(node_os.default.platform())]);
31
+ case "Local": return src.path;
32
+ default: (0, _milaboratories_ts_helpers.assertNever)(src);
33
+ }
32
34
  }
33
35
  const osToBinaryName = {
34
- linux: "platforma",
35
- macos: "platforma",
36
- windows: "platforma.exe",
36
+ linux: "platforma",
37
+ macos: "platforma",
38
+ windows: "platforma.exe"
37
39
  };
38
40
 
41
+ //#endregion
39
42
  exports.newDefaultPlBinarySource = newDefaultPlBinarySource;
40
- exports.osToBinaryName = osToBinaryName;
41
43
  exports.resolveLocalPlBinaryPath = resolveLocalPlBinaryPath;
42
- //# sourceMappingURL=pl_binary.cjs.map
44
+ //# sourceMappingURL=pl_binary.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"pl_binary.cjs","sources":["../../src/common/pl_binary.ts"],"sourcesContent":["import type { MiLogger } from \"@milaboratories/ts-helpers\";\nimport { assertNever } from \"@milaboratories/ts-helpers\";\nimport { downloadBinary } from \"./pl_binary_download\";\nimport { getDefaultPlVersion } from \"./pl_version\";\nimport os from \"node:os\";\nimport upath from \"upath\";\nimport type { OSType } from \"./os_and_arch\";\nimport { newOs } from \"./os_and_arch\";\nimport type { Dispatcher } from \"undici\";\n\n/** Shows how the binary should be got. */\nexport type PlBinarySource = PlBinarySourceDownload | PlBinarySourceLocal;\n\nexport type PlBinarySourceDownload = {\n readonly type: \"Download\";\n readonly version: string;\n};\n\nexport type PlBinarySourceLocal = {\n readonly type: \"Local\";\n readonly path: string;\n};\n\nexport function newDefaultPlBinarySource(): PlBinarySourceDownload {\n return { type: \"Download\", version: getDefaultPlVersion() };\n}\n\nexport async function resolveLocalPlBinaryPath({\n logger,\n downloadDir,\n src,\n dispatcher,\n}: {\n logger: MiLogger;\n downloadDir: string;\n src: PlBinarySource;\n dispatcher?: Dispatcher;\n}): Promise<string> {\n switch (src.type) {\n case \"Download\":\n // eslint-disable-next-line no-case-declarations\n const ops = await downloadBinary({\n logger,\n baseDir: downloadDir,\n softwareName: \"pl\",\n archiveName: `pl-${src.version}`,\n arch: os.arch(),\n platform: os.platform(),\n dispatcher,\n });\n return upath.join(ops.baseName, \"binaries\", osToBinaryName[newOs(os.platform())]);\n\n case \"Local\":\n return src.path;\n\n default:\n assertNever(src);\n }\n}\n\nexport const osToBinaryName: Record<OSType, string> = {\n linux: \"platforma\",\n macos: \"platforma\",\n windows: \"platforma.exe\",\n};\n"],"names":["getDefaultPlVersion","downloadBinary","newOs","assertNever"],"mappings":";;;;;;;;;SAuBgB,wBAAwB,GAAA;IACtC,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAEA,8BAAmB,EAAE,EAAE;AAC7D;AAEO,eAAe,wBAAwB,CAAC,EAC7C,MAAM,EACN,WAAW,EACX,GAAG,EACH,UAAU,GAMX,EAAA;AACC,IAAA,QAAQ,GAAG,CAAC,IAAI;AACd,QAAA,KAAK,UAAU;;AAEb,YAAA,MAAM,GAAG,GAAG,MAAMC,iCAAc,CAAC;gBAC/B,MAAM;AACN,gBAAA,OAAO,EAAE,WAAW;AACpB,gBAAA,YAAY,EAAE,IAAI;AAClB,gBAAA,WAAW,EAAE,CAAA,GAAA,EAAM,GAAG,CAAC,OAAO,CAAA,CAAE;AAChC,gBAAA,IAAI,EAAE,EAAE,CAAC,IAAI,EAAE;AACf,gBAAA,QAAQ,EAAE,EAAE,CAAC,QAAQ,EAAE;gBACvB,UAAU;AACX,aAAA,CAAC;YACF,OAAO,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,EAAE,UAAU,EAAE,cAAc,CAACC,iBAAK,CAAC,EAAE,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;AAEnF,QAAA,KAAK,OAAO;YACV,OAAO,GAAG,CAAC,IAAI;AAEjB,QAAA;YACEC,qBAAW,CAAC,GAAG,CAAC;;AAEtB;AAEO,MAAM,cAAc,GAA2B;AACpD,IAAA,KAAK,EAAE,WAAW;AAClB,IAAA,KAAK,EAAE,WAAW;AAClB,IAAA,OAAO,EAAE,eAAe;;;;;;;"}
1
+ {"version":3,"file":"pl_binary.cjs","names":["getDefaultPlVersion","downloadBinary","os","newOs"],"sources":["../../src/common/pl_binary.ts"],"sourcesContent":["import type { MiLogger } from \"@milaboratories/ts-helpers\";\nimport { assertNever } from \"@milaboratories/ts-helpers\";\nimport { downloadBinary } from \"./pl_binary_download\";\nimport { getDefaultPlVersion } from \"./pl_version\";\nimport os from \"node:os\";\nimport upath from \"upath\";\nimport type { OSType } from \"./os_and_arch\";\nimport { newOs } from \"./os_and_arch\";\nimport type { Dispatcher } from \"undici\";\n\n/** Shows how the binary should be got. */\nexport type PlBinarySource = PlBinarySourceDownload | PlBinarySourceLocal;\n\nexport type PlBinarySourceDownload = {\n readonly type: \"Download\";\n readonly version: string;\n};\n\nexport type PlBinarySourceLocal = {\n readonly type: \"Local\";\n readonly path: string;\n};\n\nexport function newDefaultPlBinarySource(): PlBinarySourceDownload {\n return { type: \"Download\", version: getDefaultPlVersion() };\n}\n\nexport async function resolveLocalPlBinaryPath({\n logger,\n downloadDir,\n src,\n dispatcher,\n}: {\n logger: MiLogger;\n downloadDir: string;\n src: PlBinarySource;\n dispatcher?: Dispatcher;\n}): Promise<string> {\n switch (src.type) {\n case \"Download\":\n // eslint-disable-next-line no-case-declarations\n const ops = await downloadBinary({\n logger,\n baseDir: downloadDir,\n softwareName: \"pl\",\n archiveName: `pl-${src.version}`,\n arch: os.arch(),\n platform: os.platform(),\n dispatcher,\n });\n return upath.join(ops.baseName, \"binaries\", osToBinaryName[newOs(os.platform())]);\n\n case \"Local\":\n return src.path;\n\n default:\n assertNever(src);\n }\n}\n\nexport const osToBinaryName: Record<OSType, string> = {\n linux: \"platforma\",\n macos: \"platforma\",\n windows: \"platforma.exe\",\n};\n"],"mappings":";;;;;;;;;;;AAuBA,SAAgB,2BAAmD;AACjE,QAAO;EAAE,MAAM;EAAY,SAASA,wCAAqB;EAAE;;AAG7D,eAAsB,yBAAyB,EAC7C,QACA,aACA,KACA,cAMkB;AAClB,SAAQ,IAAI,MAAZ;EACE,KAAK;GAEH,MAAM,MAAM,MAAMC,0CAAe;IAC/B;IACA,SAAS;IACT,cAAc;IACd,aAAa,MAAM,IAAI;IACvB,MAAMC,gBAAG,MAAM;IACf,UAAUA,gBAAG,UAAU;IACvB;IACD,CAAC;AACF,UAAO,cAAM,KAAK,IAAI,UAAU,YAAY,eAAeC,0BAAMD,gBAAG,UAAU,CAAC,EAAE;EAEnF,KAAK,QACH,QAAO,IAAI;EAEb,QACE,6CAAY,IAAI;;;AAItB,MAAa,iBAAyC;CACpD,OAAO;CACP,OAAO;CACP,SAAS;CACV"}
@@ -1,22 +1,17 @@
1
- import type { MiLogger } from "@milaboratories/ts-helpers";
2
- import type { OSType } from "./os_and_arch";
3
- import type { Dispatcher } from "undici";
1
+ import { MiLogger } from "@milaboratories/ts-helpers";
2
+ import { Dispatcher } from "undici";
3
+
4
+ //#region src/common/pl_binary.d.ts
4
5
  /** Shows how the binary should be got. */
5
- export type PlBinarySource = PlBinarySourceDownload | PlBinarySourceLocal;
6
- export type PlBinarySourceDownload = {
7
- readonly type: "Download";
8
- readonly version: string;
6
+ type PlBinarySource = PlBinarySourceDownload | PlBinarySourceLocal;
7
+ type PlBinarySourceDownload = {
8
+ readonly type: "Download";
9
+ readonly version: string;
9
10
  };
10
- export type PlBinarySourceLocal = {
11
- readonly type: "Local";
12
- readonly path: string;
11
+ type PlBinarySourceLocal = {
12
+ readonly type: "Local";
13
+ readonly path: string;
13
14
  };
14
- export declare function newDefaultPlBinarySource(): PlBinarySourceDownload;
15
- export declare function resolveLocalPlBinaryPath({ logger, downloadDir, src, dispatcher, }: {
16
- logger: MiLogger;
17
- downloadDir: string;
18
- src: PlBinarySource;
19
- dispatcher?: Dispatcher;
20
- }): Promise<string>;
21
- export declare const osToBinaryName: Record<OSType, string>;
15
+ //#endregion
16
+ export { PlBinarySource, PlBinarySourceDownload };
22
17
  //# sourceMappingURL=pl_binary.d.ts.map
@@ -1,38 +1,40 @@
1
- import { assertNever } from '@milaboratories/ts-helpers';
2
- import { downloadBinary } from './pl_binary_download.js';
3
- import { getDefaultPlVersion } from './pl_version.js';
4
- import os__default from 'node:os';
5
- import upath from 'upath';
6
- import { newOs } from './os_and_arch.js';
1
+ import { newOs } from "./os_and_arch.js";
2
+ import { downloadBinary } from "./pl_binary_download.js";
3
+ import { getDefaultPlVersion } from "./pl_version.js";
4
+ import { assertNever } from "@milaboratories/ts-helpers";
5
+ import upath from "upath";
6
+ import os from "node:os";
7
7
 
8
+ //#region src/common/pl_binary.ts
8
9
  function newDefaultPlBinarySource() {
9
- return { type: "Download", version: getDefaultPlVersion() };
10
+ return {
11
+ type: "Download",
12
+ version: getDefaultPlVersion()
13
+ };
10
14
  }
11
- async function resolveLocalPlBinaryPath({ logger, downloadDir, src, dispatcher, }) {
12
- switch (src.type) {
13
- case "Download":
14
- // eslint-disable-next-line no-case-declarations
15
- const ops = await downloadBinary({
16
- logger,
17
- baseDir: downloadDir,
18
- softwareName: "pl",
19
- archiveName: `pl-${src.version}`,
20
- arch: os__default.arch(),
21
- platform: os__default.platform(),
22
- dispatcher,
23
- });
24
- return upath.join(ops.baseName, "binaries", osToBinaryName[newOs(os__default.platform())]);
25
- case "Local":
26
- return src.path;
27
- default:
28
- assertNever(src);
29
- }
15
+ async function resolveLocalPlBinaryPath({ logger, downloadDir, src, dispatcher }) {
16
+ switch (src.type) {
17
+ case "Download":
18
+ const ops = await downloadBinary({
19
+ logger,
20
+ baseDir: downloadDir,
21
+ softwareName: "pl",
22
+ archiveName: `pl-${src.version}`,
23
+ arch: os.arch(),
24
+ platform: os.platform(),
25
+ dispatcher
26
+ });
27
+ return upath.join(ops.baseName, "binaries", osToBinaryName[newOs(os.platform())]);
28
+ case "Local": return src.path;
29
+ default: assertNever(src);
30
+ }
30
31
  }
31
32
  const osToBinaryName = {
32
- linux: "platforma",
33
- macos: "platforma",
34
- windows: "platforma.exe",
33
+ linux: "platforma",
34
+ macos: "platforma",
35
+ windows: "platforma.exe"
35
36
  };
36
37
 
37
- export { newDefaultPlBinarySource, osToBinaryName, resolveLocalPlBinaryPath };
38
- //# sourceMappingURL=pl_binary.js.map
38
+ //#endregion
39
+ export { newDefaultPlBinarySource, resolveLocalPlBinaryPath };
40
+ //# sourceMappingURL=pl_binary.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pl_binary.js","sources":["../../src/common/pl_binary.ts"],"sourcesContent":["import type { MiLogger } from \"@milaboratories/ts-helpers\";\nimport { assertNever } from \"@milaboratories/ts-helpers\";\nimport { downloadBinary } from \"./pl_binary_download\";\nimport { getDefaultPlVersion } from \"./pl_version\";\nimport os from \"node:os\";\nimport upath from \"upath\";\nimport type { OSType } from \"./os_and_arch\";\nimport { newOs } from \"./os_and_arch\";\nimport type { Dispatcher } from \"undici\";\n\n/** Shows how the binary should be got. */\nexport type PlBinarySource = PlBinarySourceDownload | PlBinarySourceLocal;\n\nexport type PlBinarySourceDownload = {\n readonly type: \"Download\";\n readonly version: string;\n};\n\nexport type PlBinarySourceLocal = {\n readonly type: \"Local\";\n readonly path: string;\n};\n\nexport function newDefaultPlBinarySource(): PlBinarySourceDownload {\n return { type: \"Download\", version: getDefaultPlVersion() };\n}\n\nexport async function resolveLocalPlBinaryPath({\n logger,\n downloadDir,\n src,\n dispatcher,\n}: {\n logger: MiLogger;\n downloadDir: string;\n src: PlBinarySource;\n dispatcher?: Dispatcher;\n}): Promise<string> {\n switch (src.type) {\n case \"Download\":\n // eslint-disable-next-line no-case-declarations\n const ops = await downloadBinary({\n logger,\n baseDir: downloadDir,\n softwareName: \"pl\",\n archiveName: `pl-${src.version}`,\n arch: os.arch(),\n platform: os.platform(),\n dispatcher,\n });\n return upath.join(ops.baseName, \"binaries\", osToBinaryName[newOs(os.platform())]);\n\n case \"Local\":\n return src.path;\n\n default:\n assertNever(src);\n }\n}\n\nexport const osToBinaryName: Record<OSType, string> = {\n linux: \"platforma\",\n macos: \"platforma\",\n windows: \"platforma.exe\",\n};\n"],"names":["os"],"mappings":";;;;;;;SAuBgB,wBAAwB,GAAA;IACtC,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,mBAAmB,EAAE,EAAE;AAC7D;AAEO,eAAe,wBAAwB,CAAC,EAC7C,MAAM,EACN,WAAW,EACX,GAAG,EACH,UAAU,GAMX,EAAA;AACC,IAAA,QAAQ,GAAG,CAAC,IAAI;AACd,QAAA,KAAK,UAAU;;AAEb,YAAA,MAAM,GAAG,GAAG,MAAM,cAAc,CAAC;gBAC/B,MAAM;AACN,gBAAA,OAAO,EAAE,WAAW;AACpB,gBAAA,YAAY,EAAE,IAAI;AAClB,gBAAA,WAAW,EAAE,CAAA,GAAA,EAAM,GAAG,CAAC,OAAO,CAAA,CAAE;AAChC,gBAAA,IAAI,EAAEA,WAAE,CAAC,IAAI,EAAE;AACf,gBAAA,QAAQ,EAAEA,WAAE,CAAC,QAAQ,EAAE;gBACvB,UAAU;AACX,aAAA,CAAC;YACF,OAAO,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,QAAQ,EAAE,UAAU,EAAE,cAAc,CAAC,KAAK,CAACA,WAAE,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;AAEnF,QAAA,KAAK,OAAO;YACV,OAAO,GAAG,CAAC,IAAI;AAEjB,QAAA;YACE,WAAW,CAAC,GAAG,CAAC;;AAEtB;AAEO,MAAM,cAAc,GAA2B;AACpD,IAAA,KAAK,EAAE,WAAW;AAClB,IAAA,KAAK,EAAE,WAAW;AAClB,IAAA,OAAO,EAAE,eAAe;;;;;"}
1
+ {"version":3,"file":"pl_binary.js","names":[],"sources":["../../src/common/pl_binary.ts"],"sourcesContent":["import type { MiLogger } from \"@milaboratories/ts-helpers\";\nimport { assertNever } from \"@milaboratories/ts-helpers\";\nimport { downloadBinary } from \"./pl_binary_download\";\nimport { getDefaultPlVersion } from \"./pl_version\";\nimport os from \"node:os\";\nimport upath from \"upath\";\nimport type { OSType } from \"./os_and_arch\";\nimport { newOs } from \"./os_and_arch\";\nimport type { Dispatcher } from \"undici\";\n\n/** Shows how the binary should be got. */\nexport type PlBinarySource = PlBinarySourceDownload | PlBinarySourceLocal;\n\nexport type PlBinarySourceDownload = {\n readonly type: \"Download\";\n readonly version: string;\n};\n\nexport type PlBinarySourceLocal = {\n readonly type: \"Local\";\n readonly path: string;\n};\n\nexport function newDefaultPlBinarySource(): PlBinarySourceDownload {\n return { type: \"Download\", version: getDefaultPlVersion() };\n}\n\nexport async function resolveLocalPlBinaryPath({\n logger,\n downloadDir,\n src,\n dispatcher,\n}: {\n logger: MiLogger;\n downloadDir: string;\n src: PlBinarySource;\n dispatcher?: Dispatcher;\n}): Promise<string> {\n switch (src.type) {\n case \"Download\":\n // eslint-disable-next-line no-case-declarations\n const ops = await downloadBinary({\n logger,\n baseDir: downloadDir,\n softwareName: \"pl\",\n archiveName: `pl-${src.version}`,\n arch: os.arch(),\n platform: os.platform(),\n dispatcher,\n });\n return upath.join(ops.baseName, \"binaries\", osToBinaryName[newOs(os.platform())]);\n\n case \"Local\":\n return src.path;\n\n default:\n assertNever(src);\n }\n}\n\nexport const osToBinaryName: Record<OSType, string> = {\n linux: \"platforma\",\n macos: \"platforma\",\n windows: \"platforma.exe\",\n};\n"],"mappings":";;;;;;;;AAuBA,SAAgB,2BAAmD;AACjE,QAAO;EAAE,MAAM;EAAY,SAAS,qBAAqB;EAAE;;AAG7D,eAAsB,yBAAyB,EAC7C,QACA,aACA,KACA,cAMkB;AAClB,SAAQ,IAAI,MAAZ;EACE,KAAK;GAEH,MAAM,MAAM,MAAM,eAAe;IAC/B;IACA,SAAS;IACT,cAAc;IACd,aAAa,MAAM,IAAI;IACvB,MAAM,GAAG,MAAM;IACf,UAAU,GAAG,UAAU;IACvB;IACD,CAAC;AACF,UAAO,MAAM,KAAK,IAAI,UAAU,YAAY,eAAe,MAAM,GAAG,UAAU,CAAC,EAAE;EAEnF,KAAK,QACH,QAAO,IAAI;EAEb,QACE,aAAY,IAAI;;;AAItB,MAAa,iBAAyC;CACpD,OAAO;CACP,OAAO;CACP,SAAS;CACV"}