@uipath/filesystem 0.1.7 → 0.9.0
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 +6 -2
- package/dist/browser.d.ts +4 -0
- package/dist/index.browser.js +1367 -18269
- package/dist/index.js +7 -0
- package/dist/interfaces.d.ts +1 -0
- package/dist/node.d.ts +1 -0
- package/package.json +8 -8
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @uipath/filesystem
|
|
2
2
|
|
|
3
|
-
Cross-platform filesystem abstraction for the UiPath CLI. Provides a unified interface for file operations in both Node.js and browser environments.
|
|
3
|
+
Cross-platform filesystem abstraction for the UiPath CLI. Provides a unified interface for file operations in both Node.js and browser environments. The browser implementation uses LightningFS with IndexedDB-backed persistence.
|
|
4
4
|
|
|
5
5
|
## Installation
|
|
6
6
|
|
|
@@ -60,4 +60,8 @@ Returns a singleton `IFileSystem` instance.
|
|
|
60
60
|
|
|
61
61
|
## License
|
|
62
62
|
|
|
63
|
-
See the [root repository](https://github.com/UiPath/
|
|
63
|
+
See the [root repository](https://github.com/UiPath/cli) for license information.
|
|
64
|
+
|
|
65
|
+
## Browser Storage Migration
|
|
66
|
+
|
|
67
|
+
The browser backend now uses LightningFS instead of ZenFS. Existing browser-side data stored through the old ZenFS backend is not migrated and can be discarded.
|
package/dist/browser.d.ts
CHANGED
|
@@ -1,17 +1,20 @@
|
|
|
1
1
|
import type { FileSystemStats, IEnv, IFileSystem, IPath, IUtils } from "./interfaces.js";
|
|
2
2
|
export declare class BrowserFileSystem implements IFileSystem {
|
|
3
3
|
private initialized;
|
|
4
|
+
private fsInstance;
|
|
4
5
|
init(): Promise<void>;
|
|
5
6
|
private normalizePath;
|
|
6
7
|
path: IPath;
|
|
7
8
|
env: IEnv;
|
|
8
9
|
utils: IUtils;
|
|
9
10
|
prepare(): Promise<void>;
|
|
11
|
+
private getFs;
|
|
10
12
|
readFile(path: string): Promise<Uint8Array | null>;
|
|
11
13
|
readFile(path: string, options: {
|
|
12
14
|
encoding: "utf-8";
|
|
13
15
|
} | "utf-8"): Promise<string | null>;
|
|
14
16
|
writeFile(filePath: string, data: string | Uint8Array): Promise<void>;
|
|
17
|
+
appendFile(filePath: string, data: string | Uint8Array): Promise<void>;
|
|
15
18
|
readdir(path: string): Promise<string[]>;
|
|
16
19
|
stat(path: string): Promise<FileSystemStats | null>;
|
|
17
20
|
exists(path: string): Promise<boolean>;
|
|
@@ -22,4 +25,5 @@ export declare class BrowserFileSystem implements IFileSystem {
|
|
|
22
25
|
copyDirectory(sourcePath: string, destPath: string): Promise<void>;
|
|
23
26
|
private isEnoent;
|
|
24
27
|
private isEexist;
|
|
28
|
+
private checkRootDirectory;
|
|
25
29
|
}
|