@lmzhen/dsh-evolution-io 0.1.0-rc.7 → 0.1.0-rc.70
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/lib/types/index.d.ts +22 -0
- package/package.json +3 -3
package/lib/types/index.d.ts
CHANGED
|
@@ -12,6 +12,28 @@ export interface EvolutionIo {
|
|
|
12
12
|
exists(path: string): Promise<boolean>;
|
|
13
13
|
rename(path: string, destination: string): Promise<void>;
|
|
14
14
|
copy(path: string, destination: string): Promise<void>;
|
|
15
|
+
/**
|
|
16
|
+
* Optional byte-size probe for the read guard. Return the file's size in
|
|
17
|
+
* bytes, or `null` when unknown (unsupported backend, missing file, stat
|
|
18
|
+
* failure). An implementation without this probe gets no read guard.
|
|
19
|
+
*/
|
|
20
|
+
size?(path: string, signal?: AbortSignal): Promise<number | null>;
|
|
21
|
+
/**
|
|
22
|
+
* Optional atomic read-modify-write (rc.50 P2-2): the read and the write run
|
|
23
|
+
* inside a single cross-process lock so two processes sharing DSH_HOME
|
|
24
|
+
* cannot interleave their RMW sequences. Backends without it fall back to
|
|
25
|
+
* plain read+write and the consumer keeps its single-process chain as the
|
|
26
|
+
* second layer. Mirrors `EvolutionIoLike.transact` in core — providers that
|
|
27
|
+
* implement it (e.g. `nodeEvolutionIo`) expose it here, and consumers read
|
|
28
|
+
* it through `transactIo` / the evolution IO adapter.
|
|
29
|
+
*/
|
|
30
|
+
transact?(this: void, path: string, task: (current: string | null) => Promise<string | null>): Promise<void>;
|
|
31
|
+
/**
|
|
32
|
+
* Optional symlink probe (G7). `true` = the path is a symlink, `false` = a
|
|
33
|
+
* real entry, `null` = guard not applicable. Consumers treat `null` as
|
|
34
|
+
* "let it through". Mirrors `EvolutionIoLike.isSymlink`.
|
|
35
|
+
*/
|
|
36
|
+
isSymlink?(this: void, path: string): Promise<boolean | null>;
|
|
15
37
|
}
|
|
16
38
|
declare module '@deepseek-ai/cordis' {
|
|
17
39
|
interface Context {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lmzhen/dsh-evolution-io",
|
|
3
3
|
"description": "IO seam for evolution providers (community build)",
|
|
4
|
-
"version": "0.1.0-rc.
|
|
4
|
+
"version": "0.1.0-rc.70",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -35,10 +35,10 @@
|
|
|
35
35
|
"@deepseek-ai/schemastery": "^3.18.1"
|
|
36
36
|
},
|
|
37
37
|
"peerDependencies": {
|
|
38
|
-
"@deepseek-ai/dsh-invariants": "^0.1.
|
|
38
|
+
"@deepseek-ai/dsh-invariants": "^0.1.1-rc.2",
|
|
39
39
|
"@deepseek-ai/cordis": "^4.0.1"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@deepseek-ai/dsh-invariants": "^0.1.
|
|
42
|
+
"@deepseek-ai/dsh-invariants": "^0.1.1-rc.2"
|
|
43
43
|
}
|
|
44
44
|
}
|