@uipath/filesystem 0.9.1 → 1.0.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/dist/browser.d.ts +1 -0
- package/dist/index.browser.js +3 -0
- package/dist/index.js +10 -1
- package/dist/interfaces.d.ts +6 -0
- package/dist/node.d.ts +1 -0
- package/package.json +4 -4
package/dist/browser.d.ts
CHANGED
|
@@ -21,6 +21,7 @@ export declare class BrowserFileSystem implements IFileSystem {
|
|
|
21
21
|
mkdir(path: string): Promise<void>;
|
|
22
22
|
rm(path: string): Promise<void>;
|
|
23
23
|
rename(oldPath: string, newPath: string): Promise<void>;
|
|
24
|
+
realpath(filePath: string): Promise<string>;
|
|
24
25
|
getTempDir(): Promise<string>;
|
|
25
26
|
copyDirectory(sourcePath: string, destPath: string): Promise<void>;
|
|
26
27
|
private isEnoent;
|
package/dist/index.browser.js
CHANGED
|
@@ -1605,6 +1605,9 @@ class BrowserFileSystem {
|
|
|
1605
1605
|
const fs = this.getFs();
|
|
1606
1606
|
await fs.promises.rename(oldPath, newPath);
|
|
1607
1607
|
}
|
|
1608
|
+
async realpath(filePath) {
|
|
1609
|
+
return filePath;
|
|
1610
|
+
}
|
|
1608
1611
|
async getTempDir() {
|
|
1609
1612
|
const dir = `/tmp/uipath-fs-${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
|
|
1610
1613
|
await this.mkdir(dir);
|
package/dist/index.js
CHANGED
|
@@ -199,7 +199,7 @@ var convertWslPathToWindows = async (path) => {
|
|
|
199
199
|
}
|
|
200
200
|
};
|
|
201
201
|
|
|
202
|
-
// ../../node_modules/define-lazy-prop/index.js
|
|
202
|
+
// ../../node_modules/open/node_modules/define-lazy-prop/index.js
|
|
203
203
|
function defineLazyProperty(object, propertyName, valueGetter) {
|
|
204
204
|
const define = (value) => Object.defineProperty(object, propertyName, { value, enumerable: true, writable: true });
|
|
205
205
|
Object.defineProperty(object, propertyName, {
|
|
@@ -697,6 +697,15 @@ class NodeFileSystem {
|
|
|
697
697
|
async rename(oldPath, newPath) {
|
|
698
698
|
await fs6.rename(oldPath, newPath);
|
|
699
699
|
}
|
|
700
|
+
async realpath(filePath) {
|
|
701
|
+
try {
|
|
702
|
+
return await fs6.realpath(filePath);
|
|
703
|
+
} catch (error) {
|
|
704
|
+
if (this.isEnoent(error))
|
|
705
|
+
return filePath;
|
|
706
|
+
throw error;
|
|
707
|
+
}
|
|
708
|
+
}
|
|
700
709
|
async getTempDir() {
|
|
701
710
|
return await fs6.mkdtemp(path2.join(os2.tmpdir(), "uipath-fs-"));
|
|
702
711
|
}
|
package/dist/interfaces.d.ts
CHANGED
|
@@ -34,6 +34,12 @@ export interface IFileSystem {
|
|
|
34
34
|
mkdir(path: string): Promise<void>;
|
|
35
35
|
rm(path: string): Promise<void>;
|
|
36
36
|
rename(oldPath: string, newPath: string): Promise<void>;
|
|
37
|
+
/**
|
|
38
|
+
* Canonicalize `path` by resolving symlinks and normalizing case on
|
|
39
|
+
* case-insensitive filesystems. Returns the original path unchanged on
|
|
40
|
+
* platforms / backends without symlink semantics (browser).
|
|
41
|
+
*/
|
|
42
|
+
realpath(path: string): Promise<string>;
|
|
37
43
|
getTempDir(): Promise<string>;
|
|
38
44
|
copyDirectory(sourcePath: string, destPath: string): Promise<void>;
|
|
39
45
|
path: IPath;
|
package/dist/node.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ export declare class NodeFileSystem implements IFileSystem {
|
|
|
15
15
|
mkdir(dirPath: string): Promise<void>;
|
|
16
16
|
rm(filePath: string): Promise<void>;
|
|
17
17
|
rename(oldPath: string, newPath: string): Promise<void>;
|
|
18
|
+
realpath(filePath: string): Promise<string>;
|
|
18
19
|
getTempDir(): Promise<string>;
|
|
19
20
|
copyDirectory(sourcePath: string, destPath: string): Promise<void>;
|
|
20
21
|
private isEnoent;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uipath/filesystem",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "https://github.com/UiPath/cli.git",
|
|
@@ -45,10 +45,10 @@
|
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@isomorphic-git/lightning-fs": "^4.6.2",
|
|
48
|
-
"@types/node": "^25.5.
|
|
48
|
+
"@types/node": "^25.5.2",
|
|
49
49
|
"fake-indexeddb": "^6.2.4",
|
|
50
50
|
"open": "^11.0.0",
|
|
51
|
-
"typescript": "^
|
|
51
|
+
"typescript": "^6.0.2"
|
|
52
52
|
},
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "d982977e86057fd9d0846c955595c64865aeecab"
|
|
54
54
|
}
|