@effect/platform-node 0.19.4 → 0.19.5

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 (44) hide show
  1. package/Command/dist/effect-platform-node-Command.esm.js +0 -4
  2. package/CommandExecutor/dist/effect-platform-node-CommandExecutor.esm.js +14 -13
  3. package/Effectify/dist/effect-platform-node-Effectify.esm.js +0 -4
  4. package/Error/dist/effect-platform-node-Error.esm.js +0 -4
  5. package/FileSystem/dist/effect-platform-node-FileSystem.esm.js +12 -13
  6. package/Http/Etag/dist/effect-platform-node-Http-Etag.esm.js +3 -22
  7. package/Http/FormData/dist/effect-platform-node-Http-FormData.esm.js +15 -22
  8. package/Http/NodeClient/dist/effect-platform-node-Http-NodeClient.esm.js +24 -65
  9. package/Http/Platform/dist/effect-platform-node-Http-Platform.esm.js +19 -1
  10. package/Http/Server/dist/effect-platform-node-Http-Server.esm.js +44 -28
  11. package/HttpClient/dist/effect-platform-node-HttpClient.esm.js +19 -6
  12. package/HttpServer/dist/effect-platform-node-HttpServer.esm.js +40 -10
  13. package/KeyValueStore/dist/effect-platform-node-KeyValueStore.esm.js +17 -18
  14. package/NodeContext/dist/effect-platform-node-NodeContext.esm.js +25 -22
  15. package/Path/dist/effect-platform-node-Path.esm.js +6 -25
  16. package/Runtime/dist/effect-platform-node-Runtime.esm.js +3 -13
  17. package/Sink/dist/effect-platform-node-Sink.esm.js +5 -18
  18. package/Stream/dist/effect-platform-node-Stream.esm.js +6 -30
  19. package/dist/Command-56d67f13.esm.js +27 -0
  20. package/{internal/commandExecutor.esm.js → dist/CommandExecutor-cfc0af4b.esm.js} +27 -10
  21. package/dist/Effectify-24bba5b0.esm.js +12 -0
  22. package/dist/Error-6b032e84.esm.js +16 -0
  23. package/dist/Etag-6f08d5ed.esm.js +86 -0
  24. package/{internal/fileSystem.esm.js → dist/FileSystem-d4a3521c.esm.js} +30 -12
  25. package/dist/FormData-bafc0b9a.esm.js +43 -0
  26. package/dist/HttpClient-3e1bd3e7.esm.js +26 -0
  27. package/dist/HttpServer-331621bd.esm.js +34 -0
  28. package/dist/KeyValueStore-66bca5fd.esm.js +38 -0
  29. package/{internal/http/nodeClient.esm.js → dist/NodeClient-4070cde3.esm.js} +86 -12
  30. package/dist/NodeContext-4bca6ed4.esm.js +27 -0
  31. package/{internal/path.esm.js → dist/Path-7a81561f.esm.js} +35 -5
  32. package/{internal/runtime.esm.js → dist/Runtime-3bc7ee1e.esm.js} +18 -2
  33. package/{internal/http/server.esm.js → dist/Server-3a9f4a90.esm.js} +56 -10
  34. package/dist/Sink-554d2819.esm.js +23 -0
  35. package/dist/Stream-2d5b1ece.esm.js +37 -0
  36. package/dist/effect-platform-node.esm.js +73 -26
  37. package/{internal/error.esm.js → dist/error-4865cb95.esm.js} +1 -1
  38. package/{internal/http/formData.esm.js → dist/formData-4330f230.esm.js} +2 -2
  39. package/{internal/http/incomingMessage.esm.js → dist/incomingMessage-309eb6a5.esm.js} +2 -2
  40. package/{internal/http/platform.esm.js → dist/platform-f3d31bb1.esm.js} +3 -3
  41. package/{internal/sink.esm.js → dist/sink-bd7ef408.esm.js} +1 -1
  42. package/{internal/stream.esm.js → dist/stream-860139d3.esm.js} +1 -1
  43. package/package.json +2 -3
  44. package/internal/http/etag.esm.js +0 -47
@@ -0,0 +1,27 @@
1
+ import { env, exitCode, feed, flatten, isCommand, lines, make, pipeTo, start, stderr, stdin, stdout, stream, streamLines, string, workingDirectory } from '@effect/platform/Command';
2
+
3
+ /**
4
+ * @since 1.0.0
5
+ */
6
+
7
+ var Command = /*#__PURE__*/Object.freeze({
8
+ __proto__: null,
9
+ env: env,
10
+ exitCode: exitCode,
11
+ feed: feed,
12
+ flatten: flatten,
13
+ isCommand: isCommand,
14
+ lines: lines,
15
+ make: make,
16
+ pipeTo: pipeTo,
17
+ start: start,
18
+ stderr: stderr,
19
+ stdin: stdin,
20
+ stdout: stdout,
21
+ stream: stream,
22
+ streamLines: streamLines,
23
+ string: string,
24
+ workingDirectory: workingDirectory
25
+ });
26
+
27
+ export { Command as C };
@@ -1,5 +1,6 @@
1
1
  import * as Command from '@effect/platform/Command';
2
- import * as CommandExecutor from '@effect/platform/CommandExecutor';
2
+ import * as CommandExecutor$1 from '@effect/platform/CommandExecutor';
3
+ import { CommandExecutor as CommandExecutor$2 } from '@effect/platform/CommandExecutor';
3
4
  import * as FileSystem from '@effect/platform/FileSystem';
4
5
  import * as Effect from 'effect/Effect';
5
6
  import { pipe, constUndefined } from 'effect/Function';
@@ -8,9 +9,9 @@ import * as Option from 'effect/Option';
8
9
  import * as Sink from 'effect/Sink';
9
10
  import * as Stream from 'effect/Stream';
10
11
  import * as ChildProcess from 'node:child_process';
11
- import { handleErrnoException } from './error.esm.js';
12
- import { fromWritable } from './sink.esm.js';
13
- import { fromReadable } from './stream.esm.js';
12
+ import { h as handleErrnoException } from './error-4865cb95.esm.js';
13
+ import { f as fromWritable } from './sink-bd7ef408.esm.js';
14
+ import { f as fromReadable } from './stream-860139d3.esm.js';
14
15
 
15
16
  const inputToStdioOption = stdin => Option.match(stdin, {
16
17
  onNone: () => "inherit",
@@ -63,11 +64,11 @@ const runCommand = fileSystem => command => {
63
64
  }
64
65
  const exitCode = Effect.async(resume => {
65
66
  if (exited) {
66
- return resume(handle.exitCode !== null ? Effect.succeed(CommandExecutor.ExitCode(handle.exitCode)) : Effect.fail(toPlatformError("exitCode", new globalThis.Error(`Process interrupted due to receipt of signal: ${handle.signalCode}`), command)));
67
+ return resume(handle.exitCode !== null ? Effect.succeed(CommandExecutor$1.ExitCode(handle.exitCode)) : Effect.fail(toPlatformError("exitCode", new globalThis.Error(`Process interrupted due to receipt of signal: ${handle.signalCode}`), command)));
67
68
  }
68
69
  handle.on("exit", (code, signal) => {
69
70
  if (code !== null) {
70
- resume(Effect.succeed(CommandExecutor.ExitCode(code)));
71
+ resume(Effect.succeed(CommandExecutor$1.ExitCode(code)));
71
72
  } else {
72
73
  // If code is `null`, then `signal` must be defined. See the NodeJS
73
74
  // documentation for the `"exit"` event on a `child_process`.
@@ -94,7 +95,7 @@ const runCommand = fileSystem => command => {
94
95
  });
95
96
  });
96
97
  resume(Effect.sync(() => {
97
- const pid = CommandExecutor.ProcessId(handle.pid);
98
+ const pid = CommandExecutor$1.ProcessId(handle.pid);
98
99
  const stderr = fromReadable(() => handle.stderr, err => toPlatformError("fromReadable(stderr)", toError(err), command));
99
100
  let stdout = fromReadable(() => handle.stdout, err => toPlatformError("fromReadable(stdout)", toError(err), command));
100
101
  // TODO: add Sink.isSink
@@ -102,7 +103,7 @@ const runCommand = fileSystem => command => {
102
103
  stdout = Stream.transduce(stdout, command.stdout);
103
104
  }
104
105
  return {
105
- [CommandExecutor.ProcessTypeId]: CommandExecutor.ProcessTypeId,
106
+ [CommandExecutor$1.ProcessTypeId]: CommandExecutor$1.ProcessTypeId,
106
107
  pid,
107
108
  exitCode,
108
109
  isRunning,
@@ -143,6 +144,22 @@ const runCommand = fileSystem => command => {
143
144
  };
144
145
 
145
146
  /** @internal */
146
- const layer = /*#__PURE__*/Layer.effect(CommandExecutor.CommandExecutor, /*#__PURE__*/pipe(FileSystem.FileSystem, /*#__PURE__*/Effect.map(fileSystem => CommandExecutor.makeExecutor(runCommand(fileSystem)))));
147
+ const layer$1 = /*#__PURE__*/Layer.effect(CommandExecutor$1.CommandExecutor, /*#__PURE__*/pipe(FileSystem.FileSystem, /*#__PURE__*/Effect.map(fileSystem => CommandExecutor$1.makeExecutor(runCommand(fileSystem)))));
147
148
 
148
- export { layer };
149
+ /**
150
+ * @since 1.0.0
151
+ */
152
+
153
+ /**
154
+ * @since 1.0.0
155
+ * @category layer
156
+ */
157
+ const layer = layer$1;
158
+
159
+ var CommandExecutor = /*#__PURE__*/Object.freeze({
160
+ __proto__: null,
161
+ layer: layer,
162
+ CommandExecutor: CommandExecutor$2
163
+ });
164
+
165
+ export { CommandExecutor as C, layer as l };
@@ -0,0 +1,12 @@
1
+ import { effectify } from '@effect/platform/Effectify';
2
+
3
+ /**
4
+ * @since 1.0.0
5
+ */
6
+
7
+ var Effectify = /*#__PURE__*/Object.freeze({
8
+ __proto__: null,
9
+ effectify: effectify
10
+ });
11
+
12
+ export { Effectify as E };
@@ -0,0 +1,16 @@
1
+ import { BadArgument, PlatformError, PlatformErrorTypeId, SystemError, SystemErrorReason } from '@effect/platform/Error';
2
+
3
+ /**
4
+ * @since 1.0.0
5
+ */
6
+
7
+ var Error = /*#__PURE__*/Object.freeze({
8
+ __proto__: null,
9
+ BadArgument: BadArgument,
10
+ PlatformError: PlatformError,
11
+ PlatformErrorTypeId: PlatformErrorTypeId,
12
+ SystemError: SystemError,
13
+ SystemErrorReason: SystemErrorReason
14
+ });
15
+
16
+ export { Error as E };
@@ -0,0 +1,86 @@
1
+ import * as Etag$1 from '@effect/platform/Http/Etag';
2
+ import * as Effect from 'effect/Effect';
3
+ import * as Layer from 'effect/Layer';
4
+
5
+ function _mergeNamespaces(n, m) {
6
+ m.forEach(function (e) {
7
+ e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
8
+ if (k !== 'default' && !(k in n)) {
9
+ var d = Object.getOwnPropertyDescriptor(e, k);
10
+ Object.defineProperty(n, k, d.get ? d : {
11
+ enumerable: true,
12
+ get: function () { return e[k]; }
13
+ });
14
+ }
15
+ });
16
+ });
17
+ return Object.freeze(n);
18
+ }
19
+
20
+ const fromFileInfo = info => {
21
+ const mtime = info.mtime._tag === "Some" ? info.mtime.value.getTime().toString(16) : "0";
22
+ return `${info.size.toString(16)}-${mtime}`;
23
+ };
24
+ const fromFileWeb = file => {
25
+ return `${file.size.toString(16)}-${file.lastModified.toString(16)}`;
26
+ };
27
+
28
+ /** @internal */
29
+ const layer$1 = /*#__PURE__*/Layer.succeed(Etag$1.Generator, /*#__PURE__*/Etag$1.Generator.of({
30
+ [Etag$1.GeneratorTypeId]: Etag$1.GeneratorTypeId,
31
+ fromFileInfo(info) {
32
+ return Effect.sync(() => ({
33
+ _tag: "Strong",
34
+ value: fromFileInfo(info)
35
+ }));
36
+ },
37
+ fromFileWeb(file) {
38
+ return Effect.sync(() => ({
39
+ _tag: "Strong",
40
+ value: fromFileWeb(file)
41
+ }));
42
+ }
43
+ }));
44
+
45
+ /** @internal */
46
+ const layerWeak$1 = /*#__PURE__*/Layer.succeed(Etag$1.Generator, /*#__PURE__*/Etag$1.Generator.of({
47
+ [Etag$1.GeneratorTypeId]: Etag$1.GeneratorTypeId,
48
+ fromFileInfo(info) {
49
+ return Effect.sync(() => ({
50
+ _tag: "Weak",
51
+ value: fromFileInfo(info)
52
+ }));
53
+ },
54
+ fromFileWeb(file) {
55
+ return Effect.sync(() => ({
56
+ _tag: "Weak",
57
+ value: fromFileWeb(file)
58
+ }));
59
+ }
60
+ }));
61
+
62
+ /**
63
+ * @since 1.0.0
64
+ *
65
+ * Also includes exports from [`@effect/platform/Http/Etag`](https://effect-ts.github.io/platform/platform/Http/Etag.ts.html).
66
+ */
67
+
68
+ /**
69
+ * @since 1.0.0
70
+ * @category layers
71
+ */
72
+ const layer = layer$1;
73
+
74
+ /**
75
+ * @since 1.0.0
76
+ * @category layers
77
+ */
78
+ const layerWeak = layerWeak$1;
79
+
80
+ var Etag = /*#__PURE__*/_mergeNamespaces({
81
+ __proto__: null,
82
+ layer: layer,
83
+ layerWeak: layerWeak
84
+ }, [Etag$1]);
85
+
86
+ export { Etag as E, layerWeak as a, layer as l };
@@ -1,6 +1,7 @@
1
1
  import { effectify } from '@effect/platform/Effectify';
2
2
  import * as Error from '@effect/platform/Error';
3
- import * as FileSystem from '@effect/platform/FileSystem';
3
+ import * as FileSystem$1 from '@effect/platform/FileSystem';
4
+ import { FileSystem as FileSystem$2, Size } from '@effect/platform/FileSystem';
4
5
  import * as Effect from 'effect/Effect';
5
6
  import { pipe } from 'effect/Function';
6
7
  import * as Layer from 'effect/Layer';
@@ -9,7 +10,7 @@ import * as Crypto from 'node:crypto';
9
10
  import * as NFS from 'node:fs';
10
11
  import * as OS from 'node:os';
11
12
  import * as NodePath from 'node:path';
12
- import { handleErrnoException } from './error.esm.js';
13
+ import { h as handleErrnoException } from './error-4865cb95.esm.js';
13
14
 
14
15
  const handleBadArgument = method => err => Error.BadArgument({
15
16
  module: "FileSystem",
@@ -119,7 +120,7 @@ const makeTempDirectoryScoped = /*#__PURE__*/(() => {
119
120
  const openFactory = method => {
120
121
  const nodeOpen = effectify(NFS.open, handleErrnoException("FileSystem", method), handleBadArgument(method));
121
122
  const nodeClose = effectify(NFS.close, handleErrnoException("FileSystem", method), handleBadArgument(method));
122
- return (path, options) => pipe(Effect.acquireRelease(nodeOpen(path, options?.flag ?? "r", options?.mode), fd => Effect.orDie(nodeClose(fd))), Effect.map(fd => makeFile(FileSystem.FileDescriptor(fd), options?.flag?.startsWith("a") ?? false)));
123
+ return (path, options) => pipe(Effect.acquireRelease(nodeOpen(path, options?.flag ?? "r", options?.mode), fd => Effect.orDie(nodeClose(fd))), Effect.map(fd => makeFile(FileSystem$1.FileDescriptor(fd), options?.flag?.startsWith("a") ?? false)));
123
124
  };
124
125
  const open = /*#__PURE__*/openFactory("open");
125
126
  const makeFile = /*#__PURE__*/(() => {
@@ -137,13 +138,13 @@ const makeFile = /*#__PURE__*/(() => {
137
138
  constructor(fd, append) {
138
139
  this.fd = fd;
139
140
  this.append = append;
140
- this[FileSystem.FileTypeId] = FileSystem.FileTypeId;
141
+ this[FileSystem$1.FileTypeId] = FileSystem$1.FileTypeId;
141
142
  }
142
143
  get stat() {
143
144
  return Effect.map(nodeStat(this.fd), makeFileInfo);
144
145
  }
145
146
  seek(offset, from) {
146
- const offsetSize = FileSystem.Size(offset);
147
+ const offsetSize = FileSystem$1.Size(offset);
147
148
  return this.semaphore.withPermits(1)(Effect.sync(() => {
148
149
  if (from === "start") {
149
150
  this.position = offsetSize;
@@ -158,7 +159,7 @@ const makeFile = /*#__PURE__*/(() => {
158
159
  buffer,
159
160
  position: this.position
160
161
  })), bytesRead => {
161
- const sizeRead = FileSystem.Size(bytesRead);
162
+ const sizeRead = FileSystem$1.Size(bytesRead);
162
163
  this.position = this.position + sizeRead;
163
164
  return sizeRead;
164
165
  }));
@@ -193,7 +194,7 @@ const makeFile = /*#__PURE__*/(() => {
193
194
  }
194
195
  write(buffer) {
195
196
  return this.semaphore.withPermits(1)(Effect.map(Effect.suspend(() => nodeWrite(this.fd, buffer, undefined, undefined, this.append ? undefined : Number(this.position))), bytesWritten => {
196
- const sizeWritten = FileSystem.Size(bytesWritten);
197
+ const sizeWritten = FileSystem$1.Size(bytesWritten);
197
198
  if (!this.append) {
198
199
  this.position = this.position + sizeWritten;
199
200
  }
@@ -304,8 +305,8 @@ const makeFileInfo = stat => ({
304
305
  nlink: Option.fromNullable(stat.nlink),
305
306
  uid: Option.fromNullable(stat.uid),
306
307
  gid: Option.fromNullable(stat.gid),
307
- size: FileSystem.Size(stat.size),
308
- blksize: Option.fromNullable(FileSystem.Size(stat.blksize)),
308
+ size: FileSystem$1.Size(stat.size),
309
+ blksize: Option.fromNullable(FileSystem$1.Size(stat.blksize)),
309
310
  blocks: Option.fromNullable(stat.blocks)
310
311
  });
311
312
  const stat = /*#__PURE__*/(() => {
@@ -353,7 +354,7 @@ const writeFile = (path, data, options) => Effect.async((resume, signal) => {
353
354
  resume(Effect.fail(handleBadArgument("writeFile")(err)));
354
355
  }
355
356
  });
356
- const fileSystemImpl = /*#__PURE__*/FileSystem.make({
357
+ const fileSystemImpl = /*#__PURE__*/FileSystem$1.make({
357
358
  access,
358
359
  chmod,
359
360
  chown,
@@ -380,6 +381,23 @@ const fileSystemImpl = /*#__PURE__*/FileSystem.make({
380
381
  });
381
382
 
382
383
  /** @internal */
383
- const layer = /*#__PURE__*/Layer.succeed(FileSystem.FileSystem, fileSystemImpl);
384
+ const layer$1 = /*#__PURE__*/Layer.succeed(FileSystem$1.FileSystem, fileSystemImpl);
385
+
386
+ /**
387
+ * @since 1.0.0
388
+ */
389
+
390
+ /**
391
+ * @since 1.0.0
392
+ * @category layer
393
+ */
394
+ const layer = layer$1;
395
+
396
+ var FileSystem = /*#__PURE__*/Object.freeze({
397
+ __proto__: null,
398
+ layer: layer,
399
+ FileSystem: FileSystem$2,
400
+ Size: Size
401
+ });
384
402
 
385
- export { layer };
403
+ export { FileSystem as F, layer as l };
@@ -0,0 +1,43 @@
1
+ import { s as stream$1, f as formData$1 } from './formData-4330f230.esm.js';
2
+ import * as FormData$1 from '@effect/platform/Http/FormData';
3
+
4
+ function _mergeNamespaces(n, m) {
5
+ m.forEach(function (e) {
6
+ e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
7
+ if (k !== 'default' && !(k in n)) {
8
+ var d = Object.getOwnPropertyDescriptor(e, k);
9
+ Object.defineProperty(n, k, d.get ? d : {
10
+ enumerable: true,
11
+ get: function () { return e[k]; }
12
+ });
13
+ }
14
+ });
15
+ });
16
+ return Object.freeze(n);
17
+ }
18
+
19
+ /**
20
+ * @since 1.0.0
21
+ *
22
+ * Also includes exports from [`@effect/platform/Http/FormData`](https://effect-ts.github.io/platform/platform/Http/FormData.ts.html).
23
+ */
24
+
25
+ /**
26
+ * @since 1.0.0
27
+ * @category constructors
28
+ */
29
+ const stream = stream$1;
30
+
31
+ /**
32
+ * @since 1.0.0
33
+ * @category constructors
34
+ */
35
+ const formData = formData$1;
36
+
37
+ var FormData = /*#__PURE__*/_mergeNamespaces({
38
+ __proto__: null,
39
+ stream: stream,
40
+ formData: formData
41
+ }, [FormData$1]);
42
+
43
+ export { FormData as F, formData as f, stream as s };
@@ -0,0 +1,26 @@
1
+ import * as Body from '@effect/platform/Http/Body';
2
+ import * as Client from '@effect/platform/Http/Client';
3
+ import * as Error from '@effect/platform/Http/ClientError';
4
+ import * as ClientRequest from '@effect/platform/Http/ClientRequest';
5
+ import * as ClientResponse from '@effect/platform/Http/ClientResponse';
6
+ import * as Headers from '@effect/platform/Http/Headers';
7
+ import * as UrlParams from '@effect/platform/Http/UrlParams';
8
+ import { N as NodeClient } from './NodeClient-4070cde3.esm.js';
9
+
10
+ /**
11
+ * @since 1.0.0
12
+ */
13
+
14
+ var HttpClient = /*#__PURE__*/Object.freeze({
15
+ __proto__: null,
16
+ body: Body,
17
+ client: Client,
18
+ error: Error,
19
+ headers: Headers,
20
+ nodeClient: NodeClient,
21
+ request: ClientRequest,
22
+ response: ClientResponse,
23
+ urlParams: UrlParams
24
+ });
25
+
26
+ export { HttpClient as H };
@@ -0,0 +1,34 @@
1
+ import * as App from '@effect/platform/Http/App';
2
+ import * as Body from '@effect/platform/Http/Body';
3
+ import * as Headers from '@effect/platform/Http/Headers';
4
+ import * as Middleware from '@effect/platform/Http/Middleware';
5
+ import * as Router from '@effect/platform/Http/Router';
6
+ import * as Error from '@effect/platform/Http/ServerError';
7
+ import * as ServerRequest from '@effect/platform/Http/ServerRequest';
8
+ import * as ServerResponse from '@effect/platform/Http/ServerResponse';
9
+ import * as UrlParams from '@effect/platform/Http/UrlParams';
10
+ import { E as Etag } from './Etag-6f08d5ed.esm.js';
11
+ import { F as FormData } from './FormData-bafc0b9a.esm.js';
12
+ import { S as Server } from './Server-3a9f4a90.esm.js';
13
+
14
+ /**
15
+ * @since 1.0.0
16
+ */
17
+
18
+ var HttpServer = /*#__PURE__*/Object.freeze({
19
+ __proto__: null,
20
+ app: App,
21
+ body: Body,
22
+ error: Error,
23
+ etag: Etag,
24
+ formData: FormData,
25
+ headers: Headers,
26
+ middleware: Middleware,
27
+ request: ServerRequest,
28
+ response: ServerResponse,
29
+ router: Router,
30
+ server: Server,
31
+ urlParams: UrlParams
32
+ });
33
+
34
+ export { HttpServer as H };
@@ -0,0 +1,38 @@
1
+ import * as KeyValueStore$1 from '@effect/platform/KeyValueStore';
2
+ import * as Layer from 'effect/Layer';
3
+ import { l as layer } from './FileSystem-d4a3521c.esm.js';
4
+ import { l as layer$1 } from './Path-7a81561f.esm.js';
5
+
6
+ function _mergeNamespaces(n, m) {
7
+ m.forEach(function (e) {
8
+ e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
9
+ if (k !== 'default' && !(k in n)) {
10
+ var d = Object.getOwnPropertyDescriptor(e, k);
11
+ Object.defineProperty(n, k, d.get ? d : {
12
+ enumerable: true,
13
+ get: function () { return e[k]; }
14
+ });
15
+ }
16
+ });
17
+ });
18
+ return Object.freeze(n);
19
+ }
20
+
21
+ /**
22
+ * @since 1.0.0
23
+ *
24
+ * Also includes exports from [`@effect/platform/KeyValueStore`](https://effect-ts.github.io/platform/platform/KeyValueStore.ts.html).
25
+ */
26
+
27
+ /**
28
+ * @since 1.0.0
29
+ * @category layers
30
+ */
31
+ const layerFileSystem = directory => Layer.provide(Layer.merge(layer, layer$1), KeyValueStore$1.layerFileSystem(directory));
32
+
33
+ var KeyValueStore = /*#__PURE__*/_mergeNamespaces({
34
+ __proto__: null,
35
+ layerFileSystem: layerFileSystem
36
+ }, [KeyValueStore$1]);
37
+
38
+ export { KeyValueStore as K, layerFileSystem as l };
@@ -11,27 +11,27 @@ import * as Http from 'node:http';
11
11
  import * as Https from 'node:https';
12
12
  import { Readable } from 'node:stream';
13
13
  import { pipeline } from 'node:stream/promises';
14
- import { fromWritable } from '../../Sink/dist/effect-platform-node-Sink.esm.js';
15
- import { IncomingMessageImpl } from './incomingMessage.esm.js';
14
+ import { f as fromWritable } from './Sink-554d2819.esm.js';
15
+ import { I as IncomingMessageImpl } from './incomingMessage-309eb6a5.esm.js';
16
16
 
17
17
  /** @internal */
18
- const HttpAgentTypeId = /*#__PURE__*/Symbol.for("@effect/platform-node/Http/NodeClient/HttpAgent");
18
+ const HttpAgentTypeId$1 = /*#__PURE__*/Symbol.for("@effect/platform-node/Http/NodeClient/HttpAgent");
19
19
 
20
20
  /** @internal */
21
- const HttpAgent = /*#__PURE__*/Context.Tag(HttpAgentTypeId);
21
+ const HttpAgent$1 = /*#__PURE__*/Context.Tag(HttpAgentTypeId$1);
22
22
 
23
23
  /** @internal */
24
- const makeAgent = options => Effect.map(Effect.all([Effect.acquireRelease(Effect.sync(() => new Http.Agent(options)), agent => Effect.sync(() => agent.destroy())), Effect.acquireRelease(Effect.sync(() => new Https.Agent(options)), agent => Effect.sync(() => agent.destroy()))]), ([http, https]) => ({
25
- [HttpAgentTypeId]: HttpAgentTypeId,
24
+ const makeAgent$1 = options => Effect.map(Effect.all([Effect.acquireRelease(Effect.sync(() => new Http.Agent(options)), agent => Effect.sync(() => agent.destroy())), Effect.acquireRelease(Effect.sync(() => new Https.Agent(options)), agent => Effect.sync(() => agent.destroy()))]), ([http, https]) => ({
25
+ [HttpAgentTypeId$1]: HttpAgentTypeId$1,
26
26
  http,
27
27
  https
28
28
  }));
29
29
 
30
30
  /** @internal */
31
- const makeAgentLayer = options => Layer.scoped(HttpAgent, makeAgent(options));
31
+ const makeAgentLayer$1 = options => Layer.scoped(HttpAgent$1, makeAgent$1(options));
32
32
 
33
33
  /** @internal */
34
- const agentLayer = /*#__PURE__*/makeAgentLayer();
34
+ const agentLayer$1 = /*#__PURE__*/makeAgentLayer$1();
35
35
  const fromAgent = agent => Client.make(request => Effect.flatMap(UrlParams.makeUrl(request.url, request.urlParams, _ => Error.RequestError({
36
36
  request,
37
37
  reason: "InvalidUrl",
@@ -156,12 +156,86 @@ class ClientResponseImpl extends IncomingMessageImpl {
156
156
  }
157
157
 
158
158
  /** @internal */
159
- const make = /*#__PURE__*/Effect.map(HttpAgent, fromAgent);
159
+ const make$1 = /*#__PURE__*/Effect.map(HttpAgent$1, fromAgent);
160
160
 
161
161
  /** @internal */
162
- const layerWithoutAgent = /*#__PURE__*/Layer.effect(Client.Client, make);
162
+ const layerWithoutAgent$1 = /*#__PURE__*/Layer.effect(Client.Client, make$1);
163
163
 
164
164
  /** @internal */
165
- const layer = /*#__PURE__*/Layer.provide(agentLayer, layerWithoutAgent);
165
+ const layer$1 = /*#__PURE__*/Layer.provide(agentLayer$1, layerWithoutAgent$1);
166
166
 
167
- export { HttpAgent, HttpAgentTypeId, agentLayer, layer, layerWithoutAgent, make, makeAgent, makeAgentLayer };
167
+ /**
168
+ * @since 1.0.0
169
+ */
170
+
171
+ /**
172
+ * @since 1.0.0
173
+ * @category agent
174
+ */
175
+ const HttpAgentTypeId = HttpAgentTypeId$1;
176
+
177
+ /**
178
+ * @since 1.0.0
179
+ * @category agent
180
+ */
181
+
182
+ /**
183
+ * @since 1.0.0
184
+ * @category agent
185
+ */
186
+
187
+ /**
188
+ * @since 1.0.0
189
+ * @category agent
190
+ */
191
+ const HttpAgent = HttpAgent$1;
192
+
193
+ /**
194
+ * @since 1.0.0
195
+ * @category agent
196
+ */
197
+ const makeAgent = makeAgent$1;
198
+
199
+ /**
200
+ * @since 1.0.0
201
+ * @category agent
202
+ */
203
+ const agentLayer = agentLayer$1;
204
+
205
+ /**
206
+ * @since 1.0.0
207
+ * @category agent
208
+ */
209
+ const makeAgentLayer = makeAgentLayer$1;
210
+
211
+ /**
212
+ * @since 1.0.0
213
+ * @category constructors
214
+ */
215
+ const make = make$1;
216
+
217
+ /**
218
+ * @since 1.0.0
219
+ * @category layers
220
+ */
221
+ const layer = layer$1;
222
+
223
+ /**
224
+ * @since 1.0.0
225
+ * @category layers
226
+ */
227
+ const layerWithoutAgent = layerWithoutAgent$1;
228
+
229
+ var NodeClient = /*#__PURE__*/Object.freeze({
230
+ __proto__: null,
231
+ HttpAgentTypeId: HttpAgentTypeId,
232
+ HttpAgent: HttpAgent,
233
+ makeAgent: makeAgent,
234
+ agentLayer: agentLayer,
235
+ makeAgentLayer: makeAgentLayer,
236
+ make: make,
237
+ layer: layer,
238
+ layerWithoutAgent: layerWithoutAgent
239
+ });
240
+
241
+ export { HttpAgentTypeId as H, NodeClient as N, HttpAgent as a, agentLayer as b, makeAgentLayer as c, make as d, layerWithoutAgent as e, layer as l, makeAgent as m };
@@ -0,0 +1,27 @@
1
+ import { pipe } from 'effect/Function';
2
+ import * as Layer from 'effect/Layer';
3
+ import { l as layer$3 } from './CommandExecutor-cfc0af4b.esm.js';
4
+ import { l as layer$1 } from './FileSystem-d4a3521c.esm.js';
5
+ import { l as layer$2 } from './Path-7a81561f.esm.js';
6
+
7
+ /**
8
+ * @since 1.0.0
9
+ */
10
+
11
+ /**
12
+ * @since 1.0.0
13
+ * @category models
14
+ */
15
+
16
+ /**
17
+ * @since 1.0.0
18
+ * @category layer
19
+ */
20
+ const layer = /*#__PURE__*/pipe(layer$1, /*#__PURE__*/Layer.merge(layer$2), /*#__PURE__*/Layer.merge( /*#__PURE__*/Layer.provideMerge(layer$1, layer$3)));
21
+
22
+ var NodeContext = /*#__PURE__*/Object.freeze({
23
+ __proto__: null,
24
+ layer: layer
25
+ });
26
+
27
+ export { NodeContext as N, layer as l };