cline 1.0.0-nightly.19 → 1.0.0-nightly.20
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/cline +0 -0
- package/bin/cline-darwin-amd64 +0 -0
- package/bin/cline-darwin-arm64 +0 -0
- package/bin/cline-host +0 -0
- package/bin/cline-host-darwin-amd64 +0 -0
- package/bin/cline-host-darwin-arm64 +0 -0
- package/bin/cline-host-linux-amd64 +0 -0
- package/bin/cline-host-linux-arm64 +0 -0
- package/bin/cline-linux-amd64 +0 -0
- package/bin/cline-linux-arm64 +0 -0
- package/cline-core.js +24841 -16621
- package/extension/package.json +12 -4
- package/node_modules/b4a/LICENSE +201 -0
- package/node_modules/b4a/README.md +153 -0
- package/node_modules/b4a/browser.js +563 -0
- package/node_modules/b4a/index.js +188 -0
- package/node_modules/b4a/lib/ascii.js +31 -0
- package/node_modules/b4a/lib/base64.js +65 -0
- package/node_modules/b4a/lib/hex.js +51 -0
- package/node_modules/b4a/lib/utf16le.js +40 -0
- package/node_modules/b4a/lib/utf8.js +141 -0
- package/node_modules/b4a/package.json +49 -0
- package/node_modules/b4a/react-native.js +5 -0
- package/node_modules/bare-events/LICENSE +201 -0
- package/node_modules/bare-events/README.md +25 -0
- package/node_modules/bare-events/global.d.ts +15 -0
- package/node_modules/bare-events/global.js +5 -0
- package/node_modules/bare-events/index.d.ts +94 -0
- package/node_modules/bare-events/index.js +355 -0
- package/node_modules/bare-events/lib/errors.js +32 -0
- package/node_modules/bare-events/package.json +61 -0
- package/node_modules/bare-events/web.d.ts +79 -0
- package/node_modules/bare-events/web.js +347 -0
- package/node_modules/bare-fs/CMakeLists.txt +13 -0
- package/node_modules/bare-fs/LICENSE +201 -0
- package/node_modules/bare-fs/README.md +29 -0
- package/node_modules/bare-fs/binding.c +2238 -0
- package/node_modules/bare-fs/binding.js +1 -0
- package/node_modules/bare-fs/index.d.ts +1115 -0
- package/node_modules/bare-fs/index.js +2330 -0
- package/node_modules/bare-fs/lib/constants.d.ts +49 -0
- package/node_modules/bare-fs/lib/constants.js +49 -0
- package/node_modules/bare-fs/lib/errors.d.ts +11 -0
- package/node_modules/bare-fs/lib/errors.js +55 -0
- package/node_modules/bare-fs/package.json +71 -0
- package/node_modules/bare-fs/prebuilds/android-arm/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/android-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/android-ia32/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/android-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/darwin-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/darwin-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/ios-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/ios-arm64-simulator/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/ios-x64-simulator/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/linux-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/linux-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/win32-arm64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/prebuilds/win32-x64/bare-fs.bare +0 -0
- package/node_modules/bare-fs/promises.d.ts +282 -0
- package/node_modules/bare-fs/promises.js +90 -0
- package/node_modules/bare-os/CMakeLists.txt +13 -0
- package/node_modules/bare-os/LICENSE +201 -0
- package/node_modules/bare-os/README.md +11 -0
- package/node_modules/bare-os/binding.c +1119 -0
- package/node_modules/bare-os/binding.js +1 -0
- package/node_modules/bare-os/index.d.ts +109 -0
- package/node_modules/bare-os/index.js +99 -0
- package/node_modules/bare-os/lib/constants.js +6 -0
- package/node_modules/bare-os/lib/errors.js +22 -0
- package/node_modules/bare-os/package.json +46 -0
- package/node_modules/bare-os/prebuilds/android-arm/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/android-arm64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/android-ia32/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/android-x64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/darwin-arm64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/darwin-x64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/ios-arm64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/ios-arm64-simulator/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/ios-x64-simulator/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/linux-arm64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/linux-x64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/win32-arm64/bare-os.bare +0 -0
- package/node_modules/bare-os/prebuilds/win32-x64/bare-os.bare +0 -0
- package/node_modules/bare-path/LICENSE +201 -0
- package/node_modules/bare-path/NOTICE +28 -0
- package/node_modules/bare-path/README.md +19 -0
- package/node_modules/bare-path/index.js +11 -0
- package/node_modules/bare-path/lib/constants.js +11 -0
- package/node_modules/bare-path/lib/posix.js +242 -0
- package/node_modules/bare-path/lib/shared.js +67 -0
- package/node_modules/bare-path/lib/win32.js +513 -0
- package/node_modules/bare-path/package.json +36 -0
- package/node_modules/bare-stream/LICENSE +201 -0
- package/node_modules/bare-stream/README.md +15 -0
- package/node_modules/bare-stream/global.js +8 -0
- package/node_modules/bare-stream/index.d.ts +237 -0
- package/node_modules/bare-stream/index.js +355 -0
- package/node_modules/bare-stream/package.json +61 -0
- package/node_modules/bare-stream/promises.js +3 -0
- package/node_modules/bare-stream/web.d.ts +73 -0
- package/node_modules/bare-stream/web.js +229 -0
- package/node_modules/bare-url/CMakeLists.txt +27 -0
- package/node_modules/bare-url/LICENSE +201 -0
- package/node_modules/bare-url/README.md +19 -0
- package/node_modules/bare-url/binding.c +188 -0
- package/node_modules/bare-url/binding.js +1 -0
- package/node_modules/bare-url/global.d.ts +12 -0
- package/node_modules/bare-url/global.js +2 -0
- package/node_modules/bare-url/index.d.ts +39 -0
- package/node_modules/bare-url/index.js +450 -0
- package/node_modules/bare-url/lib/errors.d.ts +8 -0
- package/node_modules/bare-url/lib/errors.js +38 -0
- package/node_modules/bare-url/lib/url-search-params.d.ts +21 -0
- package/node_modules/bare-url/lib/url-search-params.js +176 -0
- package/node_modules/bare-url/package.json +51 -0
- package/node_modules/bare-url/prebuilds/android-arm/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/android-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/android-ia32/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/android-x64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/darwin-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/darwin-x64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/ios-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/ios-arm64-simulator/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/ios-x64-simulator/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/linux-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/linux-x64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/win32-arm64/bare-url.bare +0 -0
- package/node_modules/bare-url/prebuilds/win32-x64/bare-url.bare +0 -0
- package/node_modules/better-sqlite3/deps/download.sh +1 -1
- package/node_modules/better-sqlite3/deps/sqlite3/sqlite3.c +122 -81
- package/node_modules/better-sqlite3/deps/sqlite3/sqlite3.h +45 -45
- package/node_modules/better-sqlite3/lib/database.js +1 -1
- package/node_modules/better-sqlite3/package.json +4 -7
- package/node_modules/better-sqlite3/src/addon.cpp +47 -0
- package/node_modules/better-sqlite3/src/better_sqlite3.cpp +44 -2164
- package/node_modules/better-sqlite3/src/objects/backup.cpp +120 -0
- package/node_modules/better-sqlite3/src/objects/backup.hpp +36 -0
- package/node_modules/better-sqlite3/src/objects/database.cpp +417 -0
- package/node_modules/better-sqlite3/src/objects/database.hpp +103 -0
- package/node_modules/better-sqlite3/src/objects/statement-iterator.cpp +113 -0
- package/node_modules/better-sqlite3/src/objects/statement-iterator.hpp +50 -0
- package/node_modules/better-sqlite3/src/objects/statement.cpp +383 -0
- package/node_modules/better-sqlite3/src/objects/statement.hpp +58 -0
- package/node_modules/better-sqlite3/src/util/bind-map.cpp +73 -0
- package/node_modules/better-sqlite3/src/util/binder.cpp +193 -0
- package/node_modules/better-sqlite3/src/util/constants.cpp +172 -0
- package/node_modules/better-sqlite3/src/util/custom-aggregate.cpp +121 -0
- package/node_modules/better-sqlite3/src/util/custom-function.cpp +59 -0
- package/node_modules/better-sqlite3/src/util/custom-table.cpp +409 -0
- package/node_modules/better-sqlite3/src/util/data-converter.cpp +17 -0
- package/node_modules/better-sqlite3/src/util/data.cpp +194 -0
- package/node_modules/better-sqlite3/src/util/helpers.cpp +109 -0
- package/node_modules/better-sqlite3/src/util/macros.cpp +63 -0
- package/node_modules/better-sqlite3/src/util/query-macros.cpp +71 -0
- package/node_modules/better-sqlite3/src/util/row-builder.cpp +49 -0
- package/node_modules/events-universal/LICENSE +201 -0
- package/node_modules/events-universal/README.md +17 -0
- package/node_modules/events-universal/bare.js +1 -0
- package/node_modules/events-universal/default.js +1 -0
- package/node_modules/events-universal/index.js +1 -0
- package/node_modules/events-universal/package.json +39 -0
- package/node_modules/events-universal/react-native.js +1 -0
- package/node_modules/{fs-constants → fast-fifo}/LICENSE +1 -1
- package/node_modules/fast-fifo/README.md +78 -0
- package/node_modules/fast-fifo/fixed-size.js +39 -0
- package/node_modules/fast-fifo/index.js +48 -0
- package/node_modules/fast-fifo/package.json +28 -0
- package/node_modules/{base64-js → streamx}/LICENSE +1 -1
- package/node_modules/streamx/README.md +489 -0
- package/node_modules/streamx/index.js +1184 -0
- package/node_modules/streamx/package.json +34 -0
- package/node_modules/tar-fs/README.md +23 -34
- package/node_modules/tar-fs/index.js +211 -184
- package/node_modules/tar-fs/package.json +27 -7
- package/node_modules/tar-stream/README.md +34 -19
- package/node_modules/tar-stream/constants.js +14 -0
- package/node_modules/tar-stream/extract.js +341 -192
- package/node_modules/tar-stream/headers.js +201 -175
- package/node_modules/tar-stream/pack.js +226 -194
- package/node_modules/tar-stream/package.json +23 -46
- package/node_modules/text-decoder/LICENSE +201 -0
- package/node_modules/text-decoder/README.md +36 -0
- package/node_modules/text-decoder/index.js +64 -0
- package/node_modules/text-decoder/lib/browser-decoder.js +17 -0
- package/node_modules/text-decoder/lib/pass-through-decoder.js +19 -0
- package/node_modules/text-decoder/lib/utf8-decoder.js +104 -0
- package/node_modules/text-decoder/package.json +38 -0
- package/package.json +2 -2
- package/proto/cline/account.proto +10 -8
- package/proto/cline/browser.proto +3 -1
- package/proto/cline/checkpoints.proto +5 -3
- package/proto/cline/commands.proto +4 -2
- package/proto/cline/common.proto +5 -7
- package/proto/cline/dictation.proto +3 -1
- package/proto/cline/file.proto +36 -34
- package/proto/cline/hooks.proto +3 -2
- package/proto/cline/mcp.proto +6 -4
- package/proto/cline/models.proto +189 -19
- package/proto/cline/oca_account.proto +6 -7
- package/proto/cline/slash.proto +3 -1
- package/proto/cline/state.proto +147 -292
- package/proto/cline/task.proto +4 -2
- package/proto/cline/ui.proto +25 -24
- package/proto/cline/web.proto +3 -1
- package/proto/descriptor_set.pb +0 -0
- package/proto/host/diff.proto +5 -4
- package/proto/host/env.proto +8 -7
- package/proto/host/testing.proto +3 -3
- package/proto/host/window.proto +2 -2
- package/proto/host/workspace.proto +24 -11
- package/node_modules/base64-js/README.md +0 -34
- package/node_modules/base64-js/base64js.min.js +0 -1
- package/node_modules/base64-js/index.d.ts +0 -3
- package/node_modules/base64-js/index.js +0 -150
- package/node_modules/base64-js/package.json +0 -47
- package/node_modules/better-sqlite3/src/better_sqlite3.hpp +0 -1036
- package/node_modules/bl/.travis.yml +0 -17
- package/node_modules/bl/BufferList.js +0 -396
- package/node_modules/bl/LICENSE.md +0 -13
- package/node_modules/bl/README.md +0 -247
- package/node_modules/bl/bl.js +0 -84
- package/node_modules/bl/package.json +0 -37
- package/node_modules/bl/test/convert.js +0 -21
- package/node_modules/bl/test/indexOf.js +0 -492
- package/node_modules/bl/test/isBufferList.js +0 -32
- package/node_modules/bl/test/test.js +0 -869
- package/node_modules/buffer/AUTHORS.md +0 -70
- package/node_modules/buffer/LICENSE +0 -21
- package/node_modules/buffer/README.md +0 -410
- package/node_modules/buffer/index.d.ts +0 -186
- package/node_modules/buffer/index.js +0 -1817
- package/node_modules/buffer/package.json +0 -96
- package/node_modules/chownr/LICENSE +0 -15
- package/node_modules/chownr/README.md +0 -3
- package/node_modules/chownr/chownr.js +0 -167
- package/node_modules/chownr/package.json +0 -29
- package/node_modules/fs-constants/README.md +0 -26
- package/node_modules/fs-constants/browser.js +0 -1
- package/node_modules/fs-constants/index.js +0 -1
- package/node_modules/fs-constants/package.json +0 -19
- package/node_modules/ieee754/LICENSE +0 -11
- package/node_modules/ieee754/README.md +0 -51
- package/node_modules/ieee754/index.d.ts +0 -10
- package/node_modules/ieee754/index.js +0 -85
- package/node_modules/ieee754/package.json +0 -52
- package/node_modules/inherits/LICENSE +0 -16
- package/node_modules/inherits/README.md +0 -42
- package/node_modules/inherits/inherits.js +0 -9
- package/node_modules/inherits/inherits_browser.js +0 -27
- package/node_modules/inherits/package.json +0 -29
- package/node_modules/readable-stream/CONTRIBUTING.md +0 -38
- package/node_modules/readable-stream/GOVERNANCE.md +0 -136
- package/node_modules/readable-stream/LICENSE +0 -47
- package/node_modules/readable-stream/README.md +0 -106
- package/node_modules/readable-stream/errors-browser.js +0 -127
- package/node_modules/readable-stream/errors.js +0 -116
- package/node_modules/readable-stream/experimentalWarning.js +0 -17
- package/node_modules/readable-stream/lib/_stream_duplex.js +0 -126
- package/node_modules/readable-stream/lib/_stream_passthrough.js +0 -37
- package/node_modules/readable-stream/lib/_stream_readable.js +0 -1027
- package/node_modules/readable-stream/lib/_stream_transform.js +0 -190
- package/node_modules/readable-stream/lib/_stream_writable.js +0 -641
- package/node_modules/readable-stream/lib/internal/streams/async_iterator.js +0 -180
- package/node_modules/readable-stream/lib/internal/streams/buffer_list.js +0 -183
- package/node_modules/readable-stream/lib/internal/streams/destroy.js +0 -96
- package/node_modules/readable-stream/lib/internal/streams/end-of-stream.js +0 -86
- package/node_modules/readable-stream/lib/internal/streams/from-browser.js +0 -3
- package/node_modules/readable-stream/lib/internal/streams/from.js +0 -52
- package/node_modules/readable-stream/lib/internal/streams/pipeline.js +0 -86
- package/node_modules/readable-stream/lib/internal/streams/state.js +0 -22
- package/node_modules/readable-stream/lib/internal/streams/stream-browser.js +0 -1
- package/node_modules/readable-stream/lib/internal/streams/stream.js +0 -1
- package/node_modules/readable-stream/package.json +0 -68
- package/node_modules/readable-stream/readable-browser.js +0 -9
- package/node_modules/readable-stream/readable.js +0 -16
- package/node_modules/string_decoder/LICENSE +0 -48
- package/node_modules/string_decoder/README.md +0 -47
- package/node_modules/string_decoder/lib/string_decoder.js +0 -296
- package/node_modules/string_decoder/package.json +0 -34
- package/node_modules/tar-fs/.travis.yml +0 -6
- package/node_modules/tar-fs/test/fixtures/a/hello.txt +0 -1
- package/node_modules/tar-fs/test/fixtures/b/a/test.txt +0 -1
- package/node_modules/tar-fs/test/fixtures/d/file1 +0 -0
- package/node_modules/tar-fs/test/fixtures/d/file2 +0 -0
- package/node_modules/tar-fs/test/fixtures/d/sub-dir/file5 +0 -0
- package/node_modules/tar-fs/test/fixtures/d/sub-files/file3 +0 -0
- package/node_modules/tar-fs/test/fixtures/d/sub-files/file4 +0 -0
- package/node_modules/tar-fs/test/fixtures/e/directory/.ignore +0 -0
- package/node_modules/tar-fs/test/fixtures/e/file +0 -0
- package/node_modules/tar-fs/test/fixtures/invalid.tar +0 -0
- package/node_modules/tar-fs/test/index.js +0 -346
- package/node_modules/tar-stream/sandbox.js +0 -11
- package/node_modules/util-deprecate/History.md +0 -16
- package/node_modules/util-deprecate/LICENSE +0 -24
- package/node_modules/util-deprecate/README.md +0 -53
- package/node_modules/util-deprecate/browser.js +0 -67
- package/node_modules/util-deprecate/node.js +0 -6
- package/node_modules/util-deprecate/package.json +0 -27
- package/test-startup.sh +0 -14
|
@@ -0,0 +1,1115 @@
|
|
|
1
|
+
import EventEmitter, { EventMap } from 'bare-events'
|
|
2
|
+
import Buffer, { BufferEncoding } from 'bare-buffer'
|
|
3
|
+
import URL from 'bare-url'
|
|
4
|
+
import { Readable, Writable } from 'bare-stream'
|
|
5
|
+
import promises from './promises'
|
|
6
|
+
import constants from './lib/constants'
|
|
7
|
+
|
|
8
|
+
export { promises, constants }
|
|
9
|
+
|
|
10
|
+
type Path = string | Buffer | URL
|
|
11
|
+
|
|
12
|
+
type Flag =
|
|
13
|
+
| 'a'
|
|
14
|
+
| 'a+'
|
|
15
|
+
| 'as'
|
|
16
|
+
| 'as+'
|
|
17
|
+
| 'ax'
|
|
18
|
+
| 'ax+'
|
|
19
|
+
| 'r'
|
|
20
|
+
| 'r+'
|
|
21
|
+
| 'rs'
|
|
22
|
+
| 'rs+'
|
|
23
|
+
| 'sa'
|
|
24
|
+
| 'sa+'
|
|
25
|
+
| 'sr'
|
|
26
|
+
| 'sr+'
|
|
27
|
+
| 'w'
|
|
28
|
+
| 'w+'
|
|
29
|
+
| 'wx'
|
|
30
|
+
| 'wx+'
|
|
31
|
+
| 'xa'
|
|
32
|
+
| 'xa+'
|
|
33
|
+
| 'xw'
|
|
34
|
+
| 'xw+'
|
|
35
|
+
|
|
36
|
+
interface Callback<A extends unknown[] = []> {
|
|
37
|
+
(err: Error | null, ...args: A): void
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface Dir<T extends string | Buffer = string | Buffer>
|
|
41
|
+
extends Iterable<Dirent>,
|
|
42
|
+
AsyncIterable<Dirent> {
|
|
43
|
+
readonly path: string
|
|
44
|
+
|
|
45
|
+
read(): Promise<Dirent<T> | null>
|
|
46
|
+
read(cb: Callback<[dirent: Dirent<T> | null]>): void
|
|
47
|
+
readSync(): Dirent<T> | null
|
|
48
|
+
|
|
49
|
+
close(): Promise<void>
|
|
50
|
+
close(cb: Callback): void
|
|
51
|
+
closeSync(): void
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export class Dir {
|
|
55
|
+
private constructor(path: string, handle: ArrayBuffer, opts?: OpendirOptions)
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export interface Dirent<T extends string | Buffer = string | Buffer> {
|
|
59
|
+
readonly path: string
|
|
60
|
+
readonly name: T
|
|
61
|
+
readonly type: number
|
|
62
|
+
|
|
63
|
+
isFile(): boolean
|
|
64
|
+
isDirectory(): boolean
|
|
65
|
+
isSymbolicLink(): boolean
|
|
66
|
+
isFIFO(): boolean
|
|
67
|
+
isSocket(): boolean
|
|
68
|
+
isCharacterDevice(): boolean
|
|
69
|
+
isBlockDevice(): boolean
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export class Dirent<T extends string | Buffer = string | Buffer> {
|
|
73
|
+
private constructor(path: string, name: T, type: number)
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
export interface Stats {
|
|
77
|
+
readonly dev: number
|
|
78
|
+
readonly mode: number
|
|
79
|
+
readonly nlink: number
|
|
80
|
+
readonly uid: number
|
|
81
|
+
readonly gid: number
|
|
82
|
+
readonly rdev: number
|
|
83
|
+
readonly blksize: number
|
|
84
|
+
readonly ino: number
|
|
85
|
+
readonly size: number
|
|
86
|
+
readonly blocks: number
|
|
87
|
+
readonly atimeMs: Date
|
|
88
|
+
readonly mtimeMs: Date
|
|
89
|
+
readonly ctimeMs: Date
|
|
90
|
+
readonly birthtimeMs: Date
|
|
91
|
+
|
|
92
|
+
isDirectory(): boolean
|
|
93
|
+
isFile(): boolean
|
|
94
|
+
isBlockDevice(): boolean
|
|
95
|
+
isCharacterDevice(): boolean
|
|
96
|
+
isFIFO(): boolean
|
|
97
|
+
isSymbolicLink(): boolean
|
|
98
|
+
isSocket(): boolean
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
export class Stats {
|
|
102
|
+
private constructor(
|
|
103
|
+
dev: number,
|
|
104
|
+
mode: number,
|
|
105
|
+
nlink: number,
|
|
106
|
+
uid: number,
|
|
107
|
+
gid: number,
|
|
108
|
+
rdev: number,
|
|
109
|
+
blksize: number,
|
|
110
|
+
ino: number,
|
|
111
|
+
size: number,
|
|
112
|
+
blocks: number,
|
|
113
|
+
atimeMs: number,
|
|
114
|
+
mtimeMs: number,
|
|
115
|
+
ctimeMs: number,
|
|
116
|
+
birthtimeMs: number
|
|
117
|
+
)
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
export interface ReadStreamOptions {
|
|
121
|
+
fd?: number
|
|
122
|
+
flags?: Flag
|
|
123
|
+
mode?: number
|
|
124
|
+
start?: number
|
|
125
|
+
end?: number
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export interface ReadStream extends Readable {
|
|
129
|
+
readonly path: string | null
|
|
130
|
+
readonly fd: number
|
|
131
|
+
readonly flags: Flag
|
|
132
|
+
readonly mode: number
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
export class ReadStream {
|
|
136
|
+
private constructor(path: Path | null, opts?: WriteStreamOptions)
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export function createReadStream(path: Path | null, opts?: ReadStreamOptions): ReadStream
|
|
140
|
+
|
|
141
|
+
export interface WriteStreamOptions {
|
|
142
|
+
fd?: number
|
|
143
|
+
flags?: Flag
|
|
144
|
+
mode?: number
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
export interface WriteStream extends Writable {
|
|
148
|
+
readonly path: string | null
|
|
149
|
+
readonly fd: number
|
|
150
|
+
readonly flags: Flag
|
|
151
|
+
readonly mode: number
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
export class WriteStream {
|
|
155
|
+
private constructor(path: Path | null, opts?: WriteStreamOptions)
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
export function createWriteStream(path: Path | null, opts?: WriteStreamOptions): WriteStream
|
|
159
|
+
|
|
160
|
+
export interface WatcherOptions {
|
|
161
|
+
persistent?: boolean
|
|
162
|
+
recursive?: boolean
|
|
163
|
+
encoding?: BufferEncoding | 'buffer'
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
export type WatcherEventType = 'rename' | 'change'
|
|
167
|
+
|
|
168
|
+
export interface WatcherEvents<T extends string | Buffer = string | Buffer> extends EventMap {
|
|
169
|
+
error: [err: Error]
|
|
170
|
+
change: [eventType: WatcherEventType, filename: T]
|
|
171
|
+
close: []
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
export interface Watcher<T extends string | Buffer = string | Buffer>
|
|
175
|
+
extends EventEmitter<WatcherEvents<T>>,
|
|
176
|
+
AsyncIterable<{ eventType: WatcherEventType; filename: T }> {
|
|
177
|
+
close(): void
|
|
178
|
+
ref(): void
|
|
179
|
+
unref(): void
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
export class Watcher {
|
|
183
|
+
private constructor(path: Path, opts: WatcherOptions)
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
export function access(filepath: Path, mode?: number): Promise<void>
|
|
187
|
+
|
|
188
|
+
export function access(filepath: Path, mode: number, cb: Callback): void
|
|
189
|
+
|
|
190
|
+
export function access(filepath: Path, cb: Callback): void
|
|
191
|
+
|
|
192
|
+
export function accessSync(filepath: Path, mode?: number): void
|
|
193
|
+
|
|
194
|
+
export interface AppendFileOptions {
|
|
195
|
+
encoding?: BufferEncoding
|
|
196
|
+
flag?: string
|
|
197
|
+
mode?: number
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
export function appendFile(
|
|
201
|
+
filepath: Path,
|
|
202
|
+
data: string | Buffer | ArrayBufferView,
|
|
203
|
+
opts?: AppendFileOptions
|
|
204
|
+
): Promise<void>
|
|
205
|
+
|
|
206
|
+
export function appendFile(
|
|
207
|
+
filepath: Path,
|
|
208
|
+
data: string | Buffer | ArrayBufferView,
|
|
209
|
+
encoding: BufferEncoding
|
|
210
|
+
): Promise<void>
|
|
211
|
+
|
|
212
|
+
export function appendFile(
|
|
213
|
+
filepath: Path,
|
|
214
|
+
data: string | Buffer | ArrayBufferView,
|
|
215
|
+
opts: AppendFileOptions,
|
|
216
|
+
cb: Callback
|
|
217
|
+
): void
|
|
218
|
+
|
|
219
|
+
export function appendFile(
|
|
220
|
+
filepath: Path,
|
|
221
|
+
data: string | Buffer | ArrayBufferView,
|
|
222
|
+
encoding: BufferEncoding,
|
|
223
|
+
cb: Callback
|
|
224
|
+
): void
|
|
225
|
+
|
|
226
|
+
export function appendFile(
|
|
227
|
+
filepath: Path,
|
|
228
|
+
data: string | Buffer | ArrayBufferView,
|
|
229
|
+
cb: Callback
|
|
230
|
+
): void
|
|
231
|
+
|
|
232
|
+
export function appendFileSync(
|
|
233
|
+
filepath: Path,
|
|
234
|
+
data: string | Buffer | ArrayBufferView,
|
|
235
|
+
opts?: AppendFileOptions
|
|
236
|
+
): void
|
|
237
|
+
|
|
238
|
+
export function appendFileSync(
|
|
239
|
+
filepath: Path,
|
|
240
|
+
data: string | Buffer | ArrayBufferView,
|
|
241
|
+
encoding: BufferEncoding
|
|
242
|
+
): void
|
|
243
|
+
|
|
244
|
+
export function chmod(filepath: Path, mode: string | number): Promise<void>
|
|
245
|
+
|
|
246
|
+
export function chmod(filepath: Path, mode: string | number, cb: Callback): void
|
|
247
|
+
|
|
248
|
+
export function chmodSync(filepath: Path, mode: string | number): void
|
|
249
|
+
|
|
250
|
+
export function close(fd: number): Promise<void>
|
|
251
|
+
|
|
252
|
+
export function close(fd: number, cb: Callback): void
|
|
253
|
+
|
|
254
|
+
export function closeSync(fd: number): void
|
|
255
|
+
|
|
256
|
+
export function copyFile(src: Path, dst: Path, mode?: number): Promise<void>
|
|
257
|
+
|
|
258
|
+
export function copyFile(src: Path, dst: Path, mode: number, cb: Callback): void
|
|
259
|
+
|
|
260
|
+
export function copyFile(src: Path, dst: Path, cb: Callback): void
|
|
261
|
+
|
|
262
|
+
export function copyFileSync(src: Path, dst: Path, mode?: number): void
|
|
263
|
+
|
|
264
|
+
export interface CpOptions {
|
|
265
|
+
recursive?: boolean
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
export function cp(src: Path, dst: Path, opts?: CpOptions): Promise<void>
|
|
269
|
+
|
|
270
|
+
export function cp(src: Path, dst: Path, opts: CpOptions, cb: Callback): void
|
|
271
|
+
|
|
272
|
+
export function cp(src: Path, dst: Path, cb: Callback): void
|
|
273
|
+
|
|
274
|
+
export function exists(filepath: Path): Promise<boolean>
|
|
275
|
+
|
|
276
|
+
export function exists(filepath: Path, cb: (exists: boolean) => void): void
|
|
277
|
+
|
|
278
|
+
export function existsSync(filepath: Path): boolean
|
|
279
|
+
|
|
280
|
+
export function fchmod(fd: number, mode: string | number): Promise<void>
|
|
281
|
+
|
|
282
|
+
export function fchmod(fd: number, mode: string | number, cb: Callback): void
|
|
283
|
+
|
|
284
|
+
export function fchmodSync(fd: number, mode: string | number): void
|
|
285
|
+
|
|
286
|
+
export function fstat(fd: number): Promise<Stats>
|
|
287
|
+
|
|
288
|
+
export function fstat(fd: number, cb: Callback<[stats: Stats | null]>): void
|
|
289
|
+
|
|
290
|
+
export function fstatSync(fd: number): Stats
|
|
291
|
+
|
|
292
|
+
export function ftruncate(fd: number, len?: number): Promise<void>
|
|
293
|
+
|
|
294
|
+
export function ftruncate(fd: number, len: number, cb: Callback): void
|
|
295
|
+
|
|
296
|
+
export function ftruncate(fd: number, cb: Callback): void
|
|
297
|
+
|
|
298
|
+
export function ftruncateSync(fd: number, len?: number): void
|
|
299
|
+
|
|
300
|
+
export function lstat(filepath: Path): Promise<Stats>
|
|
301
|
+
|
|
302
|
+
export function lstat(filepath: Path, cb: Callback<[stats: Stats | null]>): void
|
|
303
|
+
|
|
304
|
+
export function lstatSync(filepath: Path): Stats
|
|
305
|
+
|
|
306
|
+
export interface MkdirOptions {
|
|
307
|
+
mode?: number
|
|
308
|
+
recursive?: boolean
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
export function mkdir(filepath: Path, opts?: MkdirOptions): Promise<void>
|
|
312
|
+
|
|
313
|
+
export function mkdir(filepath: Path, mode: number): Promise<void>
|
|
314
|
+
|
|
315
|
+
export function mkdir(filepath: Path, opts: MkdirOptions, cb: Callback): void
|
|
316
|
+
|
|
317
|
+
export function mkdir(filepath: Path, mode: number, cb: Callback): void
|
|
318
|
+
|
|
319
|
+
export function mkdir(filepath: Path, cb: Callback): void
|
|
320
|
+
|
|
321
|
+
export function mkdirSync(filepath: Path, opts?: MkdirOptions): void
|
|
322
|
+
|
|
323
|
+
export function mkdirSync(filepath: Path, mode: number): void
|
|
324
|
+
|
|
325
|
+
export function open(filepath: Path, flags?: Flag | number, mode?: string | number): Promise<number>
|
|
326
|
+
|
|
327
|
+
export function open(
|
|
328
|
+
filepath: Path,
|
|
329
|
+
flags: Flag | number,
|
|
330
|
+
mode: string | number,
|
|
331
|
+
cb: Callback<[fd: number]>
|
|
332
|
+
): void
|
|
333
|
+
|
|
334
|
+
export function open(filepath: Path, flags: Flag | number, cb: Callback<[fd: number]>): void
|
|
335
|
+
|
|
336
|
+
export function open(filepath: Path, cb: Callback<[fd: number]>): void
|
|
337
|
+
|
|
338
|
+
export function openSync(filepath: Path, flags?: Flag | number, mode?: string | number): number
|
|
339
|
+
|
|
340
|
+
export interface OpendirOptions {
|
|
341
|
+
encoding?: BufferEncoding | 'buffer'
|
|
342
|
+
bufferSize?: number
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
export function opendir(
|
|
346
|
+
filepath: Path,
|
|
347
|
+
opts: OpendirOptions & { encoding?: BufferEncoding }
|
|
348
|
+
): Promise<Dir<string>>
|
|
349
|
+
|
|
350
|
+
export function opendir(
|
|
351
|
+
filepath: Path,
|
|
352
|
+
opts: OpendirOptions & { encoding: 'buffer' }
|
|
353
|
+
): Promise<Dir<Buffer>>
|
|
354
|
+
|
|
355
|
+
export function opendir(filepath: Path, opts: OpendirOptions): Promise<Dir>
|
|
356
|
+
|
|
357
|
+
export function opendir(filepath: Path, encoding: BufferEncoding): Promise<Dir<string>>
|
|
358
|
+
|
|
359
|
+
export function opendir(filepath: Path, encoding: 'buffer'): Promise<Dir<Buffer>>
|
|
360
|
+
|
|
361
|
+
export function opendir(filepath: Path, encoding: BufferEncoding | 'buffer'): Promise<Dir>
|
|
362
|
+
|
|
363
|
+
export function opendir(filepath: Path): Promise<Dir<string>>
|
|
364
|
+
|
|
365
|
+
export function opendir(
|
|
366
|
+
filepath: Path,
|
|
367
|
+
opts: OpendirOptions & { encoding?: BufferEncoding },
|
|
368
|
+
cb: Callback<[dir: Dir<string> | null]>
|
|
369
|
+
): void
|
|
370
|
+
|
|
371
|
+
export function opendir(
|
|
372
|
+
filepath: Path,
|
|
373
|
+
opts: OpendirOptions & { encoding: 'buffer' },
|
|
374
|
+
cb: Callback<[dir: Dir<Buffer> | null]>
|
|
375
|
+
): void
|
|
376
|
+
|
|
377
|
+
export function opendir(filepath: Path, opts: OpendirOptions, cb: Callback<[dir: Dir | null]>): void
|
|
378
|
+
|
|
379
|
+
export function opendir(
|
|
380
|
+
filepath: Path,
|
|
381
|
+
encoding: BufferEncoding,
|
|
382
|
+
cb: Callback<[dir: Dir<string> | null]>
|
|
383
|
+
): void
|
|
384
|
+
|
|
385
|
+
export function opendir(
|
|
386
|
+
filepath: Path,
|
|
387
|
+
encoding: 'buffer',
|
|
388
|
+
cb: Callback<[dir: Dir<Buffer> | null]>
|
|
389
|
+
): void
|
|
390
|
+
|
|
391
|
+
export function opendir(
|
|
392
|
+
filepath: Path,
|
|
393
|
+
encoding: BufferEncoding | 'buffer',
|
|
394
|
+
cb: Callback<[dir: Dir | null]>
|
|
395
|
+
): void
|
|
396
|
+
|
|
397
|
+
export function opendir(filepath: Path, cb: Callback<[dir: Dir<string> | null]>): void
|
|
398
|
+
|
|
399
|
+
export function opendirSync(
|
|
400
|
+
filepath: Path,
|
|
401
|
+
opts: OpendirOptions & { encoding?: BufferEncoding }
|
|
402
|
+
): Dir<string>
|
|
403
|
+
|
|
404
|
+
export function opendirSync(
|
|
405
|
+
filepath: Path,
|
|
406
|
+
opts: OpendirOptions & { encoding: 'buffer' }
|
|
407
|
+
): Dir<Buffer>
|
|
408
|
+
|
|
409
|
+
export function opendirSync(filepath: Path, opts: OpendirOptions): Dir
|
|
410
|
+
|
|
411
|
+
export function opendirSync(filepath: Path, encoding: BufferEncoding): Dir<string>
|
|
412
|
+
|
|
413
|
+
export function opendirSync(filepath: Path, encoding: 'buffer'): Dir<Buffer>
|
|
414
|
+
|
|
415
|
+
export function opendirSync(filepath: Path, encoding: BufferEncoding | 'buffer'): Dir
|
|
416
|
+
|
|
417
|
+
export function opendirSync(filepath: Path): Dir<string>
|
|
418
|
+
|
|
419
|
+
export function read(
|
|
420
|
+
fd: number,
|
|
421
|
+
buffer: Buffer | ArrayBufferView,
|
|
422
|
+
offset?: number,
|
|
423
|
+
len?: number,
|
|
424
|
+
pos?: number
|
|
425
|
+
): Promise<number>
|
|
426
|
+
|
|
427
|
+
export function read(
|
|
428
|
+
fd: number,
|
|
429
|
+
buffer: Buffer | ArrayBufferView,
|
|
430
|
+
offset: number,
|
|
431
|
+
len: number,
|
|
432
|
+
pos: number,
|
|
433
|
+
cb: Callback<[len: number]>
|
|
434
|
+
): void
|
|
435
|
+
|
|
436
|
+
export function read(
|
|
437
|
+
fd: number,
|
|
438
|
+
buffer: Buffer | ArrayBufferView,
|
|
439
|
+
offset: number,
|
|
440
|
+
len: number,
|
|
441
|
+
cb: Callback<[len: number]>
|
|
442
|
+
): void
|
|
443
|
+
|
|
444
|
+
export function read(
|
|
445
|
+
fd: number,
|
|
446
|
+
buffer: Buffer | ArrayBufferView,
|
|
447
|
+
offset: number,
|
|
448
|
+
cb: Callback<[len: number]>
|
|
449
|
+
): void
|
|
450
|
+
|
|
451
|
+
export function read(
|
|
452
|
+
fd: number,
|
|
453
|
+
buffer: Buffer | ArrayBufferView,
|
|
454
|
+
cb: Callback<[len: number]>
|
|
455
|
+
): void
|
|
456
|
+
|
|
457
|
+
export function readSync(
|
|
458
|
+
fd: number,
|
|
459
|
+
buffer: Buffer | ArrayBufferView,
|
|
460
|
+
offset?: number,
|
|
461
|
+
len?: number,
|
|
462
|
+
pos?: number
|
|
463
|
+
): number
|
|
464
|
+
|
|
465
|
+
export interface ReadFileOptions {
|
|
466
|
+
encoding?: BufferEncoding | 'buffer'
|
|
467
|
+
flag?: Flag
|
|
468
|
+
}
|
|
469
|
+
|
|
470
|
+
export function readFile(
|
|
471
|
+
filepath: Path,
|
|
472
|
+
opts: ReadFileOptions & { encoding: BufferEncoding }
|
|
473
|
+
): Promise<string>
|
|
474
|
+
|
|
475
|
+
export function readFile(
|
|
476
|
+
filepath: Path,
|
|
477
|
+
opts: ReadFileOptions & { encoding?: 'buffer' }
|
|
478
|
+
): Promise<Buffer>
|
|
479
|
+
|
|
480
|
+
export function readFile(filepath: Path, opts: ReadFileOptions): Promise<string | Buffer>
|
|
481
|
+
|
|
482
|
+
export function readFile(filepath: Path, encoding: BufferEncoding): Promise<string>
|
|
483
|
+
|
|
484
|
+
export function readFile(filepath: Path, encoding: 'buffer'): Promise<Buffer>
|
|
485
|
+
|
|
486
|
+
export function readFile(
|
|
487
|
+
filepath: Path,
|
|
488
|
+
encoding?: BufferEncoding | 'buffer'
|
|
489
|
+
): Promise<string | Buffer>
|
|
490
|
+
|
|
491
|
+
export function readFile(filepath: Path): Promise<Buffer>
|
|
492
|
+
|
|
493
|
+
export function readFile(
|
|
494
|
+
filepath: Path,
|
|
495
|
+
opts: ReadFileOptions & { encoding: BufferEncoding },
|
|
496
|
+
cb: Callback<[buffer?: string]>
|
|
497
|
+
): void
|
|
498
|
+
|
|
499
|
+
export function readFile(
|
|
500
|
+
filepath: Path,
|
|
501
|
+
opts: ReadFileOptions & { encoding?: 'buffer' },
|
|
502
|
+
cb: Callback<[buffer?: Buffer]>
|
|
503
|
+
): void
|
|
504
|
+
|
|
505
|
+
export function readFile(
|
|
506
|
+
filepath: Path,
|
|
507
|
+
opts: ReadFileOptions,
|
|
508
|
+
cb: Callback<[buffer?: string | Buffer]>
|
|
509
|
+
): void
|
|
510
|
+
|
|
511
|
+
export function readFile(
|
|
512
|
+
filepath: Path,
|
|
513
|
+
encoding: BufferEncoding,
|
|
514
|
+
cb: Callback<[buffer?: string]>
|
|
515
|
+
): void
|
|
516
|
+
|
|
517
|
+
export function readFile(filepath: Path, encoding: 'buffer', cb: Callback<[buffer?: Buffer]>): void
|
|
518
|
+
|
|
519
|
+
export function readFile(
|
|
520
|
+
filepath: Path,
|
|
521
|
+
encoding: BufferEncoding | 'buffer',
|
|
522
|
+
cb: Callback<[buffer?: string | Buffer]>
|
|
523
|
+
): void
|
|
524
|
+
|
|
525
|
+
export function readFile(filepath: Path, cb: Callback<[buffer?: Buffer]>): void
|
|
526
|
+
|
|
527
|
+
export function readFileSync(
|
|
528
|
+
filepath: Path,
|
|
529
|
+
opts: ReadFileOptions & { encoding: BufferEncoding }
|
|
530
|
+
): string
|
|
531
|
+
|
|
532
|
+
export function readFileSync(
|
|
533
|
+
filepath: Path,
|
|
534
|
+
opts: ReadFileOptions & { encoding?: 'buffer' }
|
|
535
|
+
): Buffer
|
|
536
|
+
|
|
537
|
+
export function readFileSync(filepath: Path, opts: ReadFileOptions): string | Buffer
|
|
538
|
+
|
|
539
|
+
export function readFileSync(filepath: Path, encoding: BufferEncoding): string
|
|
540
|
+
|
|
541
|
+
export function readFileSync(filepath: Path, encoding: 'buffer'): Buffer
|
|
542
|
+
|
|
543
|
+
export function readFileSync(filepath: Path, encoding?: BufferEncoding | 'buffer'): string | Buffer
|
|
544
|
+
|
|
545
|
+
export function readFileSync(filepath: Path): Buffer
|
|
546
|
+
|
|
547
|
+
export interface ReaddirOptions extends OpendirOptions {
|
|
548
|
+
withFileTypes?: boolean
|
|
549
|
+
}
|
|
550
|
+
export function readdir(
|
|
551
|
+
filepath: Path,
|
|
552
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding }
|
|
553
|
+
): Promise<Dir<string>[] | string[]>
|
|
554
|
+
|
|
555
|
+
export function readdir(
|
|
556
|
+
filepath: Path,
|
|
557
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding; withFileTypes: true }
|
|
558
|
+
): Promise<Dir<string>[]>
|
|
559
|
+
|
|
560
|
+
export function readdir(
|
|
561
|
+
filepath: Path,
|
|
562
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding; withFileTypes?: false }
|
|
563
|
+
): Promise<string[]>
|
|
564
|
+
|
|
565
|
+
export function readdir(
|
|
566
|
+
filepath: Path,
|
|
567
|
+
opts: ReaddirOptions & { encoding: 'buffer' }
|
|
568
|
+
): Promise<Dir<Buffer>[] | Buffer[]>
|
|
569
|
+
|
|
570
|
+
export function readdir(
|
|
571
|
+
filepath: Path,
|
|
572
|
+
opts: ReaddirOptions & { encoding: 'buffer'; withFileTypes: true }
|
|
573
|
+
): Promise<Dir<Buffer>[]>
|
|
574
|
+
|
|
575
|
+
export function readdir(
|
|
576
|
+
filepath: Path,
|
|
577
|
+
opts: ReaddirOptions & { encoding: 'buffer'; withFileTypes?: false }
|
|
578
|
+
): Promise<Buffer[]>
|
|
579
|
+
|
|
580
|
+
export function readdir(
|
|
581
|
+
filepath: Path,
|
|
582
|
+
opts: ReaddirOptions & { withFileTypes: true }
|
|
583
|
+
): Promise<Dir<string | Buffer>[]>
|
|
584
|
+
|
|
585
|
+
export function readdir(
|
|
586
|
+
filepath: Path,
|
|
587
|
+
opts: ReaddirOptions & { withFileTypes?: false }
|
|
588
|
+
): Promise<string[] | Buffer[]>
|
|
589
|
+
|
|
590
|
+
export function readdir(filepath: Path, opts: ReaddirOptions): Promise<Dir[] | string[] | Buffer[]>
|
|
591
|
+
|
|
592
|
+
export function readdir(filepath: Path, encoding: BufferEncoding): Promise<string[]>
|
|
593
|
+
|
|
594
|
+
export function readdir(filepath: Path, encoding: 'buffer'): Promise<Buffer[]>
|
|
595
|
+
|
|
596
|
+
export function readdir(
|
|
597
|
+
filepath: Path,
|
|
598
|
+
encoding: BufferEncoding | 'buffer'
|
|
599
|
+
): Promise<string[] | Buffer[]>
|
|
600
|
+
|
|
601
|
+
export function readdir(filepath: Path): Promise<string[]>
|
|
602
|
+
|
|
603
|
+
export function readdir(
|
|
604
|
+
filepath: Path,
|
|
605
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding },
|
|
606
|
+
cb: Callback<[entries: Dir<string>[] | string[] | null]>
|
|
607
|
+
): void
|
|
608
|
+
|
|
609
|
+
export function readdir(
|
|
610
|
+
filepath: Path,
|
|
611
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding; withFileTypes: true },
|
|
612
|
+
cb: Callback<[entries: Dir<string>[] | null]>
|
|
613
|
+
): void
|
|
614
|
+
|
|
615
|
+
export function readdir(
|
|
616
|
+
filepath: Path,
|
|
617
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding; withFileTypes?: false },
|
|
618
|
+
cb: Callback<[entries: string[] | null]>
|
|
619
|
+
): void
|
|
620
|
+
|
|
621
|
+
export function readdir(
|
|
622
|
+
filepath: Path,
|
|
623
|
+
opts: ReaddirOptions & { encoding: 'buffer' },
|
|
624
|
+
cb: Callback<[entries: Dir<Buffer>[] | Buffer[] | null]>
|
|
625
|
+
): void
|
|
626
|
+
|
|
627
|
+
export function readdir(
|
|
628
|
+
filepath: Path,
|
|
629
|
+
opts: ReaddirOptions & { encoding: 'buffer'; withFileTypes: true },
|
|
630
|
+
cb: Callback<[entries: Dir<Buffer>[] | null]>
|
|
631
|
+
): void
|
|
632
|
+
|
|
633
|
+
export function readdir(
|
|
634
|
+
filepath: Path,
|
|
635
|
+
opts: ReaddirOptions & { encoding: 'buffer'; withFileTypes?: false },
|
|
636
|
+
cb: Callback<[entries: Buffer[] | null]>
|
|
637
|
+
): void
|
|
638
|
+
|
|
639
|
+
export function readdir(
|
|
640
|
+
filepath: Path,
|
|
641
|
+
opts: ReaddirOptions & { withFileTypes: true },
|
|
642
|
+
cb: Callback<[entries: Dir<string | Buffer>[] | null]>
|
|
643
|
+
): void
|
|
644
|
+
|
|
645
|
+
export function readdir(
|
|
646
|
+
filepath: Path,
|
|
647
|
+
opts: ReaddirOptions & { withFileTypes?: false },
|
|
648
|
+
cb: Callback<[entries: string[] | Buffer[] | null]>
|
|
649
|
+
): void
|
|
650
|
+
|
|
651
|
+
export function readdir(
|
|
652
|
+
filepath: Path,
|
|
653
|
+
opts: ReaddirOptions,
|
|
654
|
+
cb: Callback<[entries: Dir[] | string[] | Buffer[] | null]>
|
|
655
|
+
): void
|
|
656
|
+
|
|
657
|
+
export function readdir(
|
|
658
|
+
filepath: Path,
|
|
659
|
+
encoding: BufferEncoding,
|
|
660
|
+
cb: Callback<[entries: string[] | null]>
|
|
661
|
+
): void
|
|
662
|
+
|
|
663
|
+
export function readdir(
|
|
664
|
+
filepath: Path,
|
|
665
|
+
encoding: 'buffer',
|
|
666
|
+
cb: Callback<[entries: Buffer[] | null]>
|
|
667
|
+
): void
|
|
668
|
+
|
|
669
|
+
export function readdir(
|
|
670
|
+
filepath: Path,
|
|
671
|
+
encoding: BufferEncoding | 'buffer',
|
|
672
|
+
cb: Callback<[entries: string[] | Buffer[] | null]>
|
|
673
|
+
): void
|
|
674
|
+
|
|
675
|
+
export function readdir(filepath: Path, cb: Callback<[entries: string[] | null]>): void
|
|
676
|
+
|
|
677
|
+
export function readdirSync(
|
|
678
|
+
filepath: Path,
|
|
679
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding }
|
|
680
|
+
): Dir<string>[] | string[]
|
|
681
|
+
|
|
682
|
+
export function readdirSync(
|
|
683
|
+
filepath: Path,
|
|
684
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding; withFileTypes: true }
|
|
685
|
+
): Dir<string>[]
|
|
686
|
+
|
|
687
|
+
export function readdirSync(
|
|
688
|
+
filepath: Path,
|
|
689
|
+
opts: ReaddirOptions & { encoding?: BufferEncoding; withFileTypes?: false }
|
|
690
|
+
): string[]
|
|
691
|
+
|
|
692
|
+
export function readdirSync(
|
|
693
|
+
filepath: Path,
|
|
694
|
+
opts: ReaddirOptions & { encoding: 'buffer' }
|
|
695
|
+
): Dir<Buffer>[] | Buffer[]
|
|
696
|
+
|
|
697
|
+
export function readdirSync(
|
|
698
|
+
filepath: Path,
|
|
699
|
+
opts: ReaddirOptions & { encoding: 'buffer'; withFileTypes: true }
|
|
700
|
+
): Dir<Buffer>[]
|
|
701
|
+
|
|
702
|
+
export function readdirSync(
|
|
703
|
+
filepath: Path,
|
|
704
|
+
opts: ReaddirOptions & { encoding: 'buffer'; withFileTypes?: false }
|
|
705
|
+
): Buffer[]
|
|
706
|
+
|
|
707
|
+
export function readdirSync(
|
|
708
|
+
filepath: Path,
|
|
709
|
+
opts: ReaddirOptions & { withFileTypes: true }
|
|
710
|
+
): Dir<string | Buffer>[]
|
|
711
|
+
|
|
712
|
+
export function readdirSync(
|
|
713
|
+
filepath: Path,
|
|
714
|
+
opts: ReaddirOptions & { withFileTypes?: false }
|
|
715
|
+
): string[] | Buffer[]
|
|
716
|
+
|
|
717
|
+
export function readdirSync(filepath: Path, opts: ReaddirOptions): Dir[] | string[] | Buffer[]
|
|
718
|
+
|
|
719
|
+
export function readdirSync(filepath: Path, encoding: BufferEncoding): string[]
|
|
720
|
+
|
|
721
|
+
export function readdirSync(filepath: Path, encoding: 'buffer'): Buffer[]
|
|
722
|
+
|
|
723
|
+
export function readdirSync(
|
|
724
|
+
filepath: Path,
|
|
725
|
+
encoding: BufferEncoding | 'buffer'
|
|
726
|
+
): string[] | Buffer[]
|
|
727
|
+
|
|
728
|
+
export function readdirSync(filepath: Path): string[]
|
|
729
|
+
|
|
730
|
+
export interface ReadlinkOptions {
|
|
731
|
+
encoding?: BufferEncoding | 'buffer'
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
export function readlink(
|
|
735
|
+
filepath: Path,
|
|
736
|
+
opts: ReadlinkOptions & { encoding?: BufferEncoding }
|
|
737
|
+
): Promise<string>
|
|
738
|
+
|
|
739
|
+
export function readlink(
|
|
740
|
+
filepath: Path,
|
|
741
|
+
opts: ReadlinkOptions & { encoding: 'buffer' }
|
|
742
|
+
): Promise<Buffer>
|
|
743
|
+
|
|
744
|
+
export function readlink(filepath: Path, opts: ReadlinkOptions): Promise<string | Buffer>
|
|
745
|
+
|
|
746
|
+
export function readlink(filepath: Path, encoding: BufferEncoding): Promise<string>
|
|
747
|
+
|
|
748
|
+
export function readlink(filepath: Path, encoding: 'buffer'): Promise<Buffer>
|
|
749
|
+
|
|
750
|
+
export function readlink(
|
|
751
|
+
filepath: Path,
|
|
752
|
+
encoding: BufferEncoding | 'buffer'
|
|
753
|
+
): Promise<string | Buffer>
|
|
754
|
+
|
|
755
|
+
export function readlink(filepath: Path): Promise<string>
|
|
756
|
+
|
|
757
|
+
export function readlink(
|
|
758
|
+
filepath: Path,
|
|
759
|
+
opts: ReadlinkOptions & { encoding?: BufferEncoding },
|
|
760
|
+
cb: Callback<[link: string | null]>
|
|
761
|
+
): void
|
|
762
|
+
|
|
763
|
+
export function readlink(
|
|
764
|
+
filepath: Path,
|
|
765
|
+
opts: ReadlinkOptions & { encoding: 'buffer' },
|
|
766
|
+
cb: Callback<[link: Buffer | null]>
|
|
767
|
+
): void
|
|
768
|
+
|
|
769
|
+
export function readlink(
|
|
770
|
+
filepath: Path,
|
|
771
|
+
opts: ReadlinkOptions,
|
|
772
|
+
cb: Callback<[link: string | Buffer | null]>
|
|
773
|
+
): void
|
|
774
|
+
|
|
775
|
+
export function readlink(
|
|
776
|
+
filepath: Path,
|
|
777
|
+
encoding: BufferEncoding,
|
|
778
|
+
cb: Callback<[link: string | null]>
|
|
779
|
+
): void
|
|
780
|
+
|
|
781
|
+
export function readlink(
|
|
782
|
+
filepath: Path,
|
|
783
|
+
encoding: 'buffer',
|
|
784
|
+
cb: Callback<[link: Buffer | null]>
|
|
785
|
+
): void
|
|
786
|
+
|
|
787
|
+
export function readlink(
|
|
788
|
+
filepath: Path,
|
|
789
|
+
encoding: BufferEncoding | 'buffer',
|
|
790
|
+
cb: Callback<[link: string | Buffer | null]>
|
|
791
|
+
): void
|
|
792
|
+
|
|
793
|
+
export function readlink(filepath: Path, cb: Callback<[link: string | null]>): void
|
|
794
|
+
|
|
795
|
+
export function readlinkSync(
|
|
796
|
+
filepath: Path,
|
|
797
|
+
opts: ReadlinkOptions & { encoding?: BufferEncoding }
|
|
798
|
+
): string
|
|
799
|
+
|
|
800
|
+
export function readlinkSync(filepath: Path, opts: ReadlinkOptions & { encoding: 'buffer' }): Buffer
|
|
801
|
+
|
|
802
|
+
export function readlinkSync(filepath: Path, opts: ReadlinkOptions): string | Buffer
|
|
803
|
+
|
|
804
|
+
export function readlinkSync(filepath: Path, encoding: BufferEncoding): string
|
|
805
|
+
|
|
806
|
+
export function readlinkSync(filepath: Path, encoding: 'buffer'): Buffer
|
|
807
|
+
|
|
808
|
+
export function readlinkSync(filepath: Path, encoding: BufferEncoding | 'buffer'): string | Buffer
|
|
809
|
+
|
|
810
|
+
export function readlinkSync(filepath: Path): string
|
|
811
|
+
|
|
812
|
+
export function readv(fd: number, buffers: ArrayBufferView[], position?: number): Promise<number>
|
|
813
|
+
|
|
814
|
+
export function readv(
|
|
815
|
+
fd: number,
|
|
816
|
+
buffers: ArrayBufferView[],
|
|
817
|
+
position: number,
|
|
818
|
+
cb: Callback<[len: number]>
|
|
819
|
+
): void
|
|
820
|
+
|
|
821
|
+
export function readv(fd: number, buffers: ArrayBufferView[], cb: Callback<[len: number]>): void
|
|
822
|
+
|
|
823
|
+
export function readvSync(fd: number, buffers: ArrayBufferView[], position?: number): number
|
|
824
|
+
|
|
825
|
+
export interface RealpathOptions {
|
|
826
|
+
encoding?: BufferEncoding | 'buffer'
|
|
827
|
+
}
|
|
828
|
+
|
|
829
|
+
export function realpath(
|
|
830
|
+
filepath: Path,
|
|
831
|
+
opts: RealpathOptions & { encoding?: BufferEncoding }
|
|
832
|
+
): Promise<string>
|
|
833
|
+
|
|
834
|
+
export function realpath(
|
|
835
|
+
filepath: Path,
|
|
836
|
+
opts: RealpathOptions & { encoding: 'buffer' }
|
|
837
|
+
): Promise<Buffer>
|
|
838
|
+
|
|
839
|
+
export function realpath(filepath: Path, opts: RealpathOptions): Promise<string | Buffer>
|
|
840
|
+
|
|
841
|
+
export function realpath(filepath: Path, encoding: BufferEncoding): Promise<string>
|
|
842
|
+
|
|
843
|
+
export function realpath(filepath: Path, encoding: 'buffer'): Promise<Buffer>
|
|
844
|
+
|
|
845
|
+
export function realpath(
|
|
846
|
+
filepath: Path,
|
|
847
|
+
encoding: BufferEncoding | 'buffer'
|
|
848
|
+
): Promise<string | Buffer>
|
|
849
|
+
|
|
850
|
+
export function realpath(filepath: Path): Promise<string>
|
|
851
|
+
|
|
852
|
+
export function realpath(
|
|
853
|
+
filepath: Path,
|
|
854
|
+
opts: RealpathOptions & { encoding?: BufferEncoding },
|
|
855
|
+
cb: Callback<[path: string | null]>
|
|
856
|
+
): void
|
|
857
|
+
|
|
858
|
+
export function realpath(
|
|
859
|
+
filepath: Path,
|
|
860
|
+
opts: RealpathOptions & { encoding: 'buffer' },
|
|
861
|
+
cb: Callback<[path: Buffer | null]>
|
|
862
|
+
): void
|
|
863
|
+
|
|
864
|
+
export function realpath(
|
|
865
|
+
filepath: Path,
|
|
866
|
+
opts: RealpathOptions,
|
|
867
|
+
cb: Callback<[path: string | Buffer | null]>
|
|
868
|
+
): void
|
|
869
|
+
|
|
870
|
+
export function realpath(
|
|
871
|
+
filepath: Path,
|
|
872
|
+
encoding: BufferEncoding,
|
|
873
|
+
cb: Callback<[path: string | null]>
|
|
874
|
+
): void
|
|
875
|
+
|
|
876
|
+
export function realpath(
|
|
877
|
+
filepath: Path,
|
|
878
|
+
encoding: 'buffer',
|
|
879
|
+
cb: Callback<[path: Buffer | null]>
|
|
880
|
+
): void
|
|
881
|
+
|
|
882
|
+
export function realpath(
|
|
883
|
+
filepath: Path,
|
|
884
|
+
encoding: BufferEncoding | 'buffer',
|
|
885
|
+
cb: Callback<[path: string | Buffer | null]>
|
|
886
|
+
): void
|
|
887
|
+
|
|
888
|
+
export function realpath(filepath: Path, cb: Callback<[path: string | null]>): void
|
|
889
|
+
|
|
890
|
+
export function realpathSync(
|
|
891
|
+
filepath: Path,
|
|
892
|
+
opts: RealpathOptions & { encoding?: BufferEncoding }
|
|
893
|
+
): string
|
|
894
|
+
|
|
895
|
+
export function realpathSync(filepath: Path, opts: RealpathOptions & { encoding: 'buffer' }): Buffer
|
|
896
|
+
|
|
897
|
+
export function realpathSync(filepath: Path, opts: RealpathOptions): string | Buffer
|
|
898
|
+
|
|
899
|
+
export function realpathSync(filepath: Path, encoding: BufferEncoding): string
|
|
900
|
+
|
|
901
|
+
export function realpathSync(filepath: Path, encoding: 'buffer'): Buffer
|
|
902
|
+
|
|
903
|
+
export function realpathSync(filepath: Path, encoding: BufferEncoding | 'buffer'): string | Buffer
|
|
904
|
+
|
|
905
|
+
export function realpathSync(filepath: Path): string
|
|
906
|
+
|
|
907
|
+
export function rename(src: string, dst: string): Promise<void>
|
|
908
|
+
|
|
909
|
+
export function rename(src: string, dst: string, cb: Callback): void
|
|
910
|
+
|
|
911
|
+
export function renameSync(src: string, dst: string): void
|
|
912
|
+
|
|
913
|
+
export interface RmOptions {
|
|
914
|
+
force?: boolean
|
|
915
|
+
recursive?: boolean
|
|
916
|
+
}
|
|
917
|
+
|
|
918
|
+
export function rm(filepath: Path, opts?: RmOptions): Promise<void>
|
|
919
|
+
|
|
920
|
+
export function rm(filepath: Path, opts: RmOptions, cb: Callback): void
|
|
921
|
+
|
|
922
|
+
export function rm(filepath: Path, cb: Callback): void
|
|
923
|
+
|
|
924
|
+
export function rmSync(filepath: Path, opts?: RmOptions): void
|
|
925
|
+
|
|
926
|
+
export function rmdir(filepath: Path, cb: Callback): void
|
|
927
|
+
|
|
928
|
+
export function rmdirSync(filepath: Path): void
|
|
929
|
+
|
|
930
|
+
export function stat(filepath: Path): Promise<Stats>
|
|
931
|
+
|
|
932
|
+
export function stat(filepath: Path, cb: Callback<[stats: Stats | null]>): void
|
|
933
|
+
|
|
934
|
+
export function statSync(filepath: Path): Stats
|
|
935
|
+
|
|
936
|
+
export function symlink(target: Path, filepath: Path, type?: string | number): Promise<void>
|
|
937
|
+
|
|
938
|
+
export function symlink(target: Path, filepath: Path, type: string | number, cb: Callback): void
|
|
939
|
+
|
|
940
|
+
export function symlink(target: string, filepath: Path, cb: Callback): void
|
|
941
|
+
|
|
942
|
+
export function symlinkSync(target: string, filepath: Path, type?: string | number): void
|
|
943
|
+
|
|
944
|
+
export function unlink(filepath: Path): Promise<void>
|
|
945
|
+
|
|
946
|
+
export function unlink(filepath: Path, cb: Callback): void
|
|
947
|
+
|
|
948
|
+
export function unlinkSync(filepath: Path): void
|
|
949
|
+
|
|
950
|
+
export function watch(
|
|
951
|
+
filepath: Path,
|
|
952
|
+
opts: WatcherOptions & { encoding?: BufferEncoding },
|
|
953
|
+
cb: (eventType: WatcherEventType, filename: string) => void
|
|
954
|
+
): Watcher<string>
|
|
955
|
+
|
|
956
|
+
export function watch(
|
|
957
|
+
filepath: Path,
|
|
958
|
+
opts: WatcherOptions & { encoding: 'buffer' },
|
|
959
|
+
cb: (eventType: WatcherEventType, filename: Buffer) => void
|
|
960
|
+
): Watcher<Buffer>
|
|
961
|
+
|
|
962
|
+
export function watch(
|
|
963
|
+
filepath: Path,
|
|
964
|
+
opts: WatcherOptions,
|
|
965
|
+
cb: (eventType: WatcherEventType, filename: string | Buffer) => void
|
|
966
|
+
): Watcher
|
|
967
|
+
|
|
968
|
+
export function watch(
|
|
969
|
+
filepath: Path,
|
|
970
|
+
encoding: BufferEncoding,
|
|
971
|
+
cb: (evenType: WatcherEventType, filename: string) => void
|
|
972
|
+
): Watcher<string>
|
|
973
|
+
|
|
974
|
+
export function watch(
|
|
975
|
+
filepath: Path,
|
|
976
|
+
encoding: 'buffer',
|
|
977
|
+
cb: (evenType: WatcherEventType, filename: Buffer) => void
|
|
978
|
+
): Watcher<Buffer>
|
|
979
|
+
|
|
980
|
+
export function watch(
|
|
981
|
+
filepath: Path,
|
|
982
|
+
encoding: BufferEncoding | 'buffer',
|
|
983
|
+
cb: (evenType: WatcherEventType, filename: string | Buffer) => void
|
|
984
|
+
): Watcher
|
|
985
|
+
|
|
986
|
+
export function watch(
|
|
987
|
+
filepath: Path,
|
|
988
|
+
cb: (eventType: WatcherEventType, filename: string) => void
|
|
989
|
+
): Watcher<string>
|
|
990
|
+
|
|
991
|
+
export function write(
|
|
992
|
+
fd: number,
|
|
993
|
+
data: Buffer | ArrayBufferView,
|
|
994
|
+
offset?: number,
|
|
995
|
+
len?: number,
|
|
996
|
+
pos?: number
|
|
997
|
+
): Promise<number>
|
|
998
|
+
|
|
999
|
+
export function write(
|
|
1000
|
+
fd: number,
|
|
1001
|
+
data: string,
|
|
1002
|
+
pos?: number,
|
|
1003
|
+
encoding?: BufferEncoding
|
|
1004
|
+
): Promise<number>
|
|
1005
|
+
|
|
1006
|
+
export function write(
|
|
1007
|
+
fd: number,
|
|
1008
|
+
data: Buffer | ArrayBufferView,
|
|
1009
|
+
offset: number,
|
|
1010
|
+
len: number,
|
|
1011
|
+
pos: number,
|
|
1012
|
+
cb: Callback<[len: number]>
|
|
1013
|
+
): void
|
|
1014
|
+
|
|
1015
|
+
export function write(
|
|
1016
|
+
fd: number,
|
|
1017
|
+
data: Buffer | ArrayBufferView,
|
|
1018
|
+
offset: number,
|
|
1019
|
+
len: number,
|
|
1020
|
+
cb: Callback<[len: number]>
|
|
1021
|
+
): void
|
|
1022
|
+
|
|
1023
|
+
export function write(
|
|
1024
|
+
fd: number,
|
|
1025
|
+
data: string,
|
|
1026
|
+
pos: number,
|
|
1027
|
+
encoding: BufferEncoding,
|
|
1028
|
+
cb: Callback<[len: number]>
|
|
1029
|
+
): void
|
|
1030
|
+
|
|
1031
|
+
export function write(
|
|
1032
|
+
fd: number,
|
|
1033
|
+
data: Buffer | ArrayBufferView,
|
|
1034
|
+
offset: number,
|
|
1035
|
+
cb: Callback<[len: number]>
|
|
1036
|
+
): void
|
|
1037
|
+
|
|
1038
|
+
export function write(fd: number, data: string, pos: number, cb: Callback<[len: number]>): void
|
|
1039
|
+
|
|
1040
|
+
export function write(fd: number, data: Buffer | ArrayBufferView, cb: Callback<[len: number]>): void
|
|
1041
|
+
|
|
1042
|
+
export function write(fd: number, data: string, cb: Callback<[len: number]>): void
|
|
1043
|
+
|
|
1044
|
+
export function writeSync(
|
|
1045
|
+
fd: number,
|
|
1046
|
+
data: Buffer | ArrayBufferView,
|
|
1047
|
+
offset?: number,
|
|
1048
|
+
len?: number,
|
|
1049
|
+
pos?: number
|
|
1050
|
+
): number
|
|
1051
|
+
|
|
1052
|
+
export function writeSync(fd: number, data: string, pos?: number, encoding?: BufferEncoding): number
|
|
1053
|
+
|
|
1054
|
+
export interface WriteFileOptions {
|
|
1055
|
+
encoding?: BufferEncoding
|
|
1056
|
+
flag?: Flag
|
|
1057
|
+
mode?: number
|
|
1058
|
+
}
|
|
1059
|
+
|
|
1060
|
+
export function writeFile(
|
|
1061
|
+
filepath: Path,
|
|
1062
|
+
data: string | Buffer | ArrayBufferView,
|
|
1063
|
+
opts?: WriteFileOptions
|
|
1064
|
+
): Promise<void>
|
|
1065
|
+
|
|
1066
|
+
export function writeFile(
|
|
1067
|
+
filepath: Path,
|
|
1068
|
+
data: string | Buffer | ArrayBufferView,
|
|
1069
|
+
encoding: BufferEncoding
|
|
1070
|
+
): Promise<void>
|
|
1071
|
+
|
|
1072
|
+
export function writeFile(
|
|
1073
|
+
filepath: Path,
|
|
1074
|
+
data: string | Buffer | ArrayBufferView,
|
|
1075
|
+
opts: WriteFileOptions,
|
|
1076
|
+
cb: Callback
|
|
1077
|
+
): void
|
|
1078
|
+
|
|
1079
|
+
export function writeFile(
|
|
1080
|
+
filepath: Path,
|
|
1081
|
+
data: string | Buffer | ArrayBufferView,
|
|
1082
|
+
encoding: BufferEncoding,
|
|
1083
|
+
cb: Callback
|
|
1084
|
+
): void
|
|
1085
|
+
|
|
1086
|
+
export function writeFile(
|
|
1087
|
+
filepath: Path,
|
|
1088
|
+
data: string | Buffer | ArrayBufferView,
|
|
1089
|
+
cb: Callback
|
|
1090
|
+
): void
|
|
1091
|
+
|
|
1092
|
+
export function writeFileSync(
|
|
1093
|
+
filepath: Path,
|
|
1094
|
+
data: string | Buffer | ArrayBufferView,
|
|
1095
|
+
opts?: WriteFileOptions
|
|
1096
|
+
): void
|
|
1097
|
+
|
|
1098
|
+
export function writeFileSync(
|
|
1099
|
+
filepath: Path,
|
|
1100
|
+
data: string | Buffer | ArrayBufferView,
|
|
1101
|
+
encoding: BufferEncoding
|
|
1102
|
+
): void
|
|
1103
|
+
|
|
1104
|
+
export function writev(fd: number, buffers: ArrayBufferView[], pos?: number): Promise<number>
|
|
1105
|
+
|
|
1106
|
+
export function writev(
|
|
1107
|
+
fd: number,
|
|
1108
|
+
buffers: ArrayBufferView[],
|
|
1109
|
+
pos: number,
|
|
1110
|
+
cb: Callback<[len: number]>
|
|
1111
|
+
): void
|
|
1112
|
+
|
|
1113
|
+
export function writev(fd: number, buffers: ArrayBufferView[], cb: Callback<[len: number]>): void
|
|
1114
|
+
|
|
1115
|
+
export function writevSync(fd: number, buffers: ArrayBufferView[], pos?: number): number
|