@robinpath/fs 0.1.0 → 0.1.2
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/README.md +97 -97
- package/dist/fs.d.ts +1 -1
- package/dist/fs.d.ts.map +1 -1
- package/dist/fs.js +16 -14
- package/dist/fs.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/package.json +15 -3
package/README.md
CHANGED
|
@@ -1,97 +1,97 @@
|
|
|
1
|
-
# @robinpath/fs
|
|
2
|
-
|
|
3
|
-
> Read, write, copy, move, and manage files and directories
|
|
4
|
-
|
|
5
|
-
   
|
|
6
|
-
|
|
7
|
-
## Why use this module?
|
|
8
|
-
|
|
9
|
-
The `fs` module lets you:
|
|
10
|
-
|
|
11
|
-
- Read the contents of a file as a string
|
|
12
|
-
- Write content to a file, creating or overwriting it
|
|
13
|
-
- Append content to the end of a file
|
|
14
|
-
- Check whether a file or directory exists at the given path
|
|
15
|
-
- Delete a file
|
|
16
|
-
|
|
17
|
-
All functions are callable directly from RobinPath scripts with a simple, consistent API.
|
|
18
|
-
|
|
19
|
-
## Installation
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
## Quick Start
|
|
26
|
-
|
|
27
|
-
No credentials needed — start using it right away:
|
|
28
|
-
|
|
29
|
-
```robinpath
|
|
30
|
-
any "/tmp/file.txt" "hello world"
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
## Available Functions
|
|
34
|
-
|
|
35
|
-
| Function | Description |
|
|
36
|
-
|----------|-------------|
|
|
37
|
-
| `fs.read` | Read the contents of a file as a string |
|
|
38
|
-
| `fs.write` | Write content to a file, creating or overwriting it |
|
|
39
|
-
| `fs.append` | Append content to the end of a file |
|
|
40
|
-
| `fs.exists` | Check whether a file or directory exists at the given path |
|
|
41
|
-
| `fs.delete` | Delete a file |
|
|
42
|
-
| `fs.copy` | Copy a file from source to destination |
|
|
43
|
-
| `fs.move` | Move or rename a file from source to destination |
|
|
44
|
-
| `fs.rename` | Rename a file (alias for move) |
|
|
45
|
-
| `fs.list` | List the contents of a directory |
|
|
46
|
-
| `fs.mkdir` | Create a directory (recursively creates parent directories) |
|
|
47
|
-
| `fs.rmdir` | Remove a directory and its contents |
|
|
48
|
-
| `fs.stat` | Get file or directory statistics |
|
|
49
|
-
| `fs.isFile` | Check whether a path points to a regular file |
|
|
50
|
-
| `fs.isDir` | Check whether a path points to a directory |
|
|
51
|
-
|
|
52
|
-
## Examples
|
|
53
|
-
|
|
54
|
-
### Write content to a file, creating or overwriting it
|
|
55
|
-
|
|
56
|
-
```robinpath
|
|
57
|
-
any "/tmp/file.txt" "hello world"
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
### Append content to the end of a file
|
|
61
|
-
|
|
62
|
-
```robinpath
|
|
63
|
-
any "/tmp/file.txt" "more text"
|
|
64
|
-
```
|
|
65
|
-
|
|
66
|
-
### Check whether a file or directory exists at the given path
|
|
67
|
-
|
|
68
|
-
```robinpath
|
|
69
|
-
any "/tmp/file.txt"
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
## Integration with RobinPath
|
|
73
|
-
|
|
74
|
-
```typescript
|
|
75
|
-
import { RobinPath } from "@wiredwp/robinpath";
|
|
76
|
-
import Module from "@robinpath/fs";
|
|
77
|
-
|
|
78
|
-
const rp = new RobinPath();
|
|
79
|
-
rp.registerModule(Module.name, Module.functions);
|
|
80
|
-
rp.registerModuleMeta(Module.name, Module.functionMetadata);
|
|
81
|
-
|
|
82
|
-
const result = await rp.executeScript(`
|
|
83
|
-
any "/tmp/file.txt" "hello world"
|
|
84
|
-
`);
|
|
85
|
-
```
|
|
86
|
-
|
|
87
|
-
## Full API Reference
|
|
88
|
-
|
|
89
|
-
See [MODULE.md](./MODULE.md) for complete documentation including all parameters, return types, error handling, and advanced examples.
|
|
90
|
-
|
|
91
|
-
## Related Modules
|
|
92
|
-
|
|
93
|
-
- [`@robinpath/json`](../json) — JSON module for complementary functionality
|
|
94
|
-
|
|
95
|
-
## License
|
|
96
|
-
|
|
97
|
-
MIT
|
|
1
|
+
# @robinpath/fs
|
|
2
|
+
|
|
3
|
+
> Read, write, copy, move, and manage files and directories
|
|
4
|
+
|
|
5
|
+
   
|
|
6
|
+
|
|
7
|
+
## Why use this module?
|
|
8
|
+
|
|
9
|
+
The `fs` module lets you:
|
|
10
|
+
|
|
11
|
+
- Read the contents of a file as a string
|
|
12
|
+
- Write content to a file, creating or overwriting it
|
|
13
|
+
- Append content to the end of a file
|
|
14
|
+
- Check whether a file or directory exists at the given path
|
|
15
|
+
- Delete a file
|
|
16
|
+
|
|
17
|
+
All functions are callable directly from RobinPath scripts with a simple, consistent API.
|
|
18
|
+
|
|
19
|
+
## Installation
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
robinpath add @robinpath/fs
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## Quick Start
|
|
26
|
+
|
|
27
|
+
No credentials needed — start using it right away:
|
|
28
|
+
|
|
29
|
+
```robinpath
|
|
30
|
+
any "/tmp/file.txt" "hello world"
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Available Functions
|
|
34
|
+
|
|
35
|
+
| Function | Description |
|
|
36
|
+
|----------|-------------|
|
|
37
|
+
| `fs.read` | Read the contents of a file as a string |
|
|
38
|
+
| `fs.write` | Write content to a file, creating or overwriting it |
|
|
39
|
+
| `fs.append` | Append content to the end of a file |
|
|
40
|
+
| `fs.exists` | Check whether a file or directory exists at the given path |
|
|
41
|
+
| `fs.delete` | Delete a file |
|
|
42
|
+
| `fs.copy` | Copy a file from source to destination |
|
|
43
|
+
| `fs.move` | Move or rename a file from source to destination |
|
|
44
|
+
| `fs.rename` | Rename a file (alias for move) |
|
|
45
|
+
| `fs.list` | List the contents of a directory |
|
|
46
|
+
| `fs.mkdir` | Create a directory (recursively creates parent directories) |
|
|
47
|
+
| `fs.rmdir` | Remove a directory and its contents |
|
|
48
|
+
| `fs.stat` | Get file or directory statistics |
|
|
49
|
+
| `fs.isFile` | Check whether a path points to a regular file |
|
|
50
|
+
| `fs.isDir` | Check whether a path points to a directory |
|
|
51
|
+
|
|
52
|
+
## Examples
|
|
53
|
+
|
|
54
|
+
### Write content to a file, creating or overwriting it
|
|
55
|
+
|
|
56
|
+
```robinpath
|
|
57
|
+
any "/tmp/file.txt" "hello world"
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### Append content to the end of a file
|
|
61
|
+
|
|
62
|
+
```robinpath
|
|
63
|
+
any "/tmp/file.txt" "more text"
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
### Check whether a file or directory exists at the given path
|
|
67
|
+
|
|
68
|
+
```robinpath
|
|
69
|
+
any "/tmp/file.txt"
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
## Integration with RobinPath
|
|
73
|
+
|
|
74
|
+
```typescript
|
|
75
|
+
import { RobinPath } from "@wiredwp/robinpath";
|
|
76
|
+
import Module from "@robinpath/fs";
|
|
77
|
+
|
|
78
|
+
const rp = new RobinPath();
|
|
79
|
+
rp.registerModule(Module.name, Module.functions);
|
|
80
|
+
rp.registerModuleMeta(Module.name, Module.functionMetadata);
|
|
81
|
+
|
|
82
|
+
const result = await rp.executeScript(`
|
|
83
|
+
any "/tmp/file.txt" "hello world"
|
|
84
|
+
`);
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
## Full API Reference
|
|
88
|
+
|
|
89
|
+
See [MODULE.md](./MODULE.md) for complete documentation including all parameters, return types, error handling, and advanced examples.
|
|
90
|
+
|
|
91
|
+
## Related Modules
|
|
92
|
+
|
|
93
|
+
- [`@robinpath/json`](../json) — JSON module for complementary functionality
|
|
94
|
+
|
|
95
|
+
## License
|
|
96
|
+
|
|
97
|
+
MIT
|
package/dist/fs.d.ts
CHANGED
package/dist/fs.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fs.d.ts","sourceRoot":"","sources":["../src/fs.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAoC,MAAM,
|
|
1
|
+
{"version":3,"file":"fs.d.ts","sourceRoot":"","sources":["../src/fs.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAoC,MAAM,iBAAiB,CAAC;AAmHxF,eAAO,MAAM,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,cAAc,CAetD,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8P9B,CAAC;AAEF,eAAO,MAAM,gBAAgB;;;CAkB5B,CAAC"}
|
package/dist/fs.js
CHANGED
|
@@ -1,25 +1,27 @@
|
|
|
1
|
+
import * as fsSync from "node:fs";
|
|
2
|
+
import * as fs from "node:fs/promises";
|
|
1
3
|
// -- RobinPath Function Handlers ----------------------------------------
|
|
2
4
|
const read = async (args) => {
|
|
3
5
|
const filePath = String(args[0] ?? "");
|
|
4
6
|
const encoding = (args[1] != null ? String(args[1]) : "utf-8");
|
|
5
|
-
return await
|
|
7
|
+
return await fs.readFile(filePath, { encoding });
|
|
6
8
|
};
|
|
7
9
|
const write = async (args) => {
|
|
8
10
|
const filePath = String(args[0] ?? "");
|
|
9
11
|
const content = String(args[1] ?? "");
|
|
10
|
-
await
|
|
12
|
+
await fs.writeFile(filePath, content, "utf-8");
|
|
11
13
|
return true;
|
|
12
14
|
};
|
|
13
15
|
const append = async (args) => {
|
|
14
16
|
const filePath = String(args[0] ?? "");
|
|
15
17
|
const content = String(args[1] ?? "");
|
|
16
|
-
await
|
|
18
|
+
await fs.appendFile(filePath, content, "utf-8");
|
|
17
19
|
return true;
|
|
18
20
|
};
|
|
19
21
|
const exists = async (args) => {
|
|
20
22
|
const filePath = String(args[0] ?? "");
|
|
21
23
|
try {
|
|
22
|
-
await
|
|
24
|
+
await fs.access(filePath, fsSync.constants.F_OK);
|
|
23
25
|
return true;
|
|
24
26
|
}
|
|
25
27
|
catch {
|
|
@@ -28,45 +30,45 @@ const exists = async (args) => {
|
|
|
28
30
|
};
|
|
29
31
|
const del = async (args) => {
|
|
30
32
|
const filePath = String(args[0] ?? "");
|
|
31
|
-
await
|
|
33
|
+
await fs.unlink(filePath);
|
|
32
34
|
return true;
|
|
33
35
|
};
|
|
34
36
|
const copy = async (args) => {
|
|
35
37
|
const src = String(args[0] ?? "");
|
|
36
38
|
const dest = String(args[1] ?? "");
|
|
37
|
-
await
|
|
39
|
+
await fs.copyFile(src, dest);
|
|
38
40
|
return true;
|
|
39
41
|
};
|
|
40
42
|
const move = async (args) => {
|
|
41
43
|
const src = String(args[0] ?? "");
|
|
42
44
|
const dest = String(args[1] ?? "");
|
|
43
|
-
await
|
|
45
|
+
await fs.rename(src, dest);
|
|
44
46
|
return true;
|
|
45
47
|
};
|
|
46
48
|
const rename = async (args) => {
|
|
47
49
|
const oldPath = String(args[0] ?? "");
|
|
48
50
|
const newPath = String(args[1] ?? "");
|
|
49
|
-
await
|
|
51
|
+
await fs.rename(oldPath, newPath);
|
|
50
52
|
return true;
|
|
51
53
|
};
|
|
52
54
|
const list = async (args) => {
|
|
53
55
|
const dirPath = String(args[0] ?? "");
|
|
54
|
-
const entries = await
|
|
56
|
+
const entries = await fs.readdir(dirPath);
|
|
55
57
|
return entries;
|
|
56
58
|
};
|
|
57
59
|
const mkdir = async (args) => {
|
|
58
60
|
const dirPath = String(args[0] ?? "");
|
|
59
|
-
await
|
|
61
|
+
await fs.mkdir(dirPath, { recursive: true });
|
|
60
62
|
return true;
|
|
61
63
|
};
|
|
62
64
|
const rmdir = async (args) => {
|
|
63
65
|
const dirPath = String(args[0] ?? "");
|
|
64
|
-
await
|
|
66
|
+
await fs.rm(dirPath, { recursive: true });
|
|
65
67
|
return true;
|
|
66
68
|
};
|
|
67
69
|
const stat = async (args) => {
|
|
68
70
|
const filePath = String(args[0] ?? "");
|
|
69
|
-
const stats = await
|
|
71
|
+
const stats = await fs.stat(filePath);
|
|
70
72
|
return {
|
|
71
73
|
size: stats.size,
|
|
72
74
|
isFile: stats.isFile(),
|
|
@@ -78,7 +80,7 @@ const stat = async (args) => {
|
|
|
78
80
|
const isFile = async (args) => {
|
|
79
81
|
const filePath = String(args[0] ?? "");
|
|
80
82
|
try {
|
|
81
|
-
const stats = await
|
|
83
|
+
const stats = await fs.stat(filePath);
|
|
82
84
|
return stats.isFile();
|
|
83
85
|
}
|
|
84
86
|
catch {
|
|
@@ -88,7 +90,7 @@ const isFile = async (args) => {
|
|
|
88
90
|
const isDir = async (args) => {
|
|
89
91
|
const filePath = String(args[0] ?? "");
|
|
90
92
|
try {
|
|
91
|
-
const stats = await
|
|
93
|
+
const stats = await fs.stat(filePath);
|
|
92
94
|
return stats.isDirectory();
|
|
93
95
|
}
|
|
94
96
|
catch {
|
package/dist/fs.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fs.js","sourceRoot":"","sources":["../src/fs.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"fs.js","sourceRoot":"","sources":["../src/fs.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,MAAM,SAAS,CAAC;AAClC,OAAO,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAEvC,0EAA0E;AAE1E,MAAM,IAAI,GAAmB,KAAK,EAAE,IAAI,EAAE,EAAE;IAC1C,MAAM,QAAQ,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC;IACvC,MAAM,QAAQ,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC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AAM;QACN,QAAQ;QACR,MAAM;QACN,OAAO;QACP,OAAO;QACP,MAAM;QACN,QAAQ;QACR,OAAO;KACR;CACF,CAAC"}
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAGrD,QAAA,MAAM,QAAQ,EAAE,aAMf,CAAC;AAEF,eAAe,QAAQ,CAAC;AACxB,OAAO,EAAE,QAAQ,EAAE,CAAC;AACpB,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@robinpath/fs",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -21,11 +21,23 @@
|
|
|
21
21
|
"test": "node --import tsx --test tests/*.test.ts"
|
|
22
22
|
},
|
|
23
23
|
"peerDependencies": {
|
|
24
|
-
"@
|
|
24
|
+
"@robinpath/core": ">=0.20.0"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
|
-
"@
|
|
27
|
+
"@robinpath/core": "^0.30.1",
|
|
28
28
|
"tsx": "^4.19.0",
|
|
29
29
|
"typescript": "^5.6.0"
|
|
30
|
+
},
|
|
31
|
+
"description": "Read, write, copy, move, and manage files and directories",
|
|
32
|
+
"keywords": [
|
|
33
|
+
"fs",
|
|
34
|
+
"utility"
|
|
35
|
+
],
|
|
36
|
+
"license": "MIT",
|
|
37
|
+
"robinpath": {
|
|
38
|
+
"category": "utility",
|
|
39
|
+
"type": "utility",
|
|
40
|
+
"auth": "none",
|
|
41
|
+
"functionCount": 14
|
|
30
42
|
}
|
|
31
43
|
}
|