@amalgm/core 0.5.1-main.37556559840 → 0.5.1-main.38983350397
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/PURPOSE.md +9 -7
- package/dist/identity/index.d.ts +0 -1
- package/dist/identity/index.d.ts.map +1 -1
- package/dist/identity/index.js +0 -1
- package/dist/identity/index.js.map +1 -1
- package/dist/identity/layout.d.ts +133 -171
- package/dist/identity/layout.d.ts.map +1 -1
- package/dist/identity/layout.js +191 -220
- package/dist/identity/layout.js.map +1 -1
- package/dist/identity/local/api.d.ts.map +1 -1
- package/dist/identity/local/api.js +0 -11
- package/dist/identity/local/api.js.map +1 -1
- package/dist/identity/local/types.d.ts +0 -4
- package/dist/identity/local/types.d.ts.map +1 -1
- package/dist/supervision/service-registration.d.ts +4 -4
- package/dist/supervision/service-registration.d.ts.map +1 -1
- package/dist/supervision/service-registration.js +2 -2
- package/dist/transport/routing.d.ts +1 -1
- package/dist/transport/routing.d.ts.map +1 -1
- package/package.json +4 -4
- package/dist/identity/product-state.d.ts +0 -51
- package/dist/identity/product-state.d.ts.map +0 -1
- package/dist/identity/product-state.js +0 -60
- package/dist/identity/product-state.js.map +0 -1
package/PURPOSE.md
CHANGED
|
@@ -15,8 +15,9 @@ core. Everything else is not.**
|
|
|
15
15
|
Core owns exactly four things:
|
|
16
16
|
|
|
17
17
|
1. **Identity** — who this machine is, for which user, on which branch.
|
|
18
|
-
The `~/amalgm
|
|
19
|
-
|
|
18
|
+
The lane roots (`~/amalgm`, `~/amalgm-preview`, `~/amalgm-dev/<session>`),
|
|
19
|
+
the `users/<email>/` user ground and its flat computer-only `.amalgm/`
|
|
20
|
+
folder (`layout.ts` is the only place that names them), machine/instance
|
|
20
21
|
identity, auth-store contracts, and the branch-binding rule surfaces use
|
|
21
22
|
to decide whether they may attach.
|
|
22
23
|
2. **Transport** — the pipe. The local gateway's routing and admission
|
|
@@ -152,11 +153,12 @@ instead of defining a second native installation contract.
|
|
|
152
153
|
present and newer saved-local work is durably journaled; Core never forces
|
|
153
154
|
Live to call that work `current`.
|
|
154
155
|
20. **User ground and machine state never overlap.** Everything in
|
|
155
|
-
`users/<email>/` is eligible user ground except
|
|
156
|
-
|
|
157
|
-
SQLite databases,
|
|
158
|
-
`.amalgm
|
|
159
|
-
|
|
156
|
+
`users/<email>/` is eligible user ground except any `.amalgm/` or
|
|
157
|
+
`.private/` folder and paths named by the tracked `.amalgmignore`;
|
|
158
|
+
credentials, SQLite databases, caches, runtimes, and logs live in the
|
|
159
|
+
user's flat `.amalgm/` folder or an entity's `.private/` and never enter
|
|
160
|
+
registration. A lane made by an older layout is refused ("reinstall"),
|
|
161
|
+
never migrated.
|
|
160
162
|
21. **Resume adopts the current signed release.** A stored `all` selection is
|
|
161
163
|
re-resolved against the verified catalog on every resume, and a changed
|
|
162
164
|
plan becomes durable only after its installation and runtime prove healthy.
|
package/dist/identity/index.d.ts
CHANGED
|
@@ -9,7 +9,6 @@ export * from './ports.js';
|
|
|
9
9
|
export * from './labels.js';
|
|
10
10
|
export * from './runtime-binding.js';
|
|
11
11
|
export * from './layout.js';
|
|
12
|
-
export * from './product-state.js';
|
|
13
12
|
export * from './local/index.js';
|
|
14
13
|
export * from './credentials/index.js';
|
|
15
14
|
export * from './authorization/index.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/identity/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,aAAa,CAAC;AAC5B,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/identity/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,UAAU,CAAC;AACzB,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC"}
|
package/dist/identity/index.js
CHANGED
|
@@ -9,7 +9,6 @@ export * from './ports.js';
|
|
|
9
9
|
export * from './labels.js';
|
|
10
10
|
export * from './runtime-binding.js';
|
|
11
11
|
export * from './layout.js';
|
|
12
|
-
export * from './product-state.js';
|
|
13
12
|
export * from './local/index.js';
|
|
14
13
|
export * from './credentials/index.js';
|
|
15
14
|
export * from './authorization/index.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/identity/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,aAAa,CAAC;AAC5B,cAAc,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/identity/index.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,UAAU,CAAC;AACzB,cAAc,mBAAmB,CAAC;AAClC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC"}
|
|
@@ -1,198 +1,160 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
* here is a string/record computation. Reading, writing, migrating, and
|
|
7
|
-
* resolving against the real filesystem stay host-side.
|
|
2
|
+
* Where Amalgm keeps things on disk. This file is the ONLY place that knows
|
|
3
|
+
* Amalgm's folder and file names. Shell composes these layouts once and hands
|
|
4
|
+
* each product the folders it owns; products never join an Amalgm path, never
|
|
5
|
+
* default a folder, and never read an env var to find one.
|
|
8
6
|
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
7
|
+
* ~/.amalgm/ installer home: bin, toolchains, downloads, cache
|
|
8
|
+
* <lane>/ ~/amalgm | ~/amalgm-preview | ~/amalgm-dev/<session>
|
|
9
|
+
* .amalgm-root.json lane manifest
|
|
10
|
+
* .amalgm/ lane computer-only: device, device key, launcher pointer, runtime packages, services
|
|
11
|
+
* users/<email folder>/ one user's home: agents, apps, toolbox, workspaces
|
|
12
|
+
* .amalgm/ that user's computer-only files, flat, one folder per product
|
|
12
13
|
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* macOS/Linux, where every shipped runtime lives. The grammar (segment
|
|
16
|
-
* names and nesting) is the law; the separator belongs to the host.
|
|
14
|
+
* Pure string functions. Paths are glued with `/`, which every Node file API
|
|
15
|
+
* accepts on every platform.
|
|
17
16
|
*/
|
|
17
|
+
import { type RuntimeBinding } from './runtime-binding.js';
|
|
18
18
|
import type { ClockIsoPort, RandomHexPort } from './ports.js';
|
|
19
|
-
/**
|
|
20
|
-
|
|
19
|
+
/** The layout this code reads and writes. An older lane is refused, never migrated. */
|
|
20
|
+
export declare const LAYOUT_VERSION = 2;
|
|
21
21
|
export declare const ROOT_MANIFEST_NAME = ".amalgm-root.json";
|
|
22
|
-
/** Stable user identity inside a user folder (layout.js:33). */
|
|
23
22
|
export declare const USER_MANIFEST_NAME = ".amalgm-user.json";
|
|
24
|
-
/** Root/user manifest schema version (layout.js:34). */
|
|
25
|
-
export declare const LAYOUT_VERSION = 1;
|
|
26
|
-
/** Basename of the user-home manifest (layout.js:35). The file itself lives
|
|
27
|
-
* at `system/home.json` inside the user dir — the `home-manifest` entry of
|
|
28
|
-
* {@link shippedUserHomeDeclaration}. */
|
|
29
|
-
export declare const USER_HOME_MANIFEST_NAME = "home.json";
|
|
30
|
-
/** User-home graph schema version (layout.js:38). Changing the declared
|
|
31
|
-
* exact graph changes the identity contract: a client must never accept a
|
|
32
|
-
* prior graph and silently invent a new managed child. */
|
|
33
|
-
export declare const USER_HOME_SCHEMA_VERSION = 3;
|
|
34
|
-
/** Root policy file. It is portable user ground and travels with the home
|
|
35
|
-
* whose enrollment policy it declares. */
|
|
36
23
|
export declare const USER_IGNORE_FILE_NAME = ".amalgmignore";
|
|
37
|
-
/**
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
24
|
+
/** Computer-only folder: `~/.amalgm`, `<lane>/.amalgm` and `<user>/.amalgm`. Never synced. */
|
|
25
|
+
export declare const LOCAL_DIR_NAME = ".amalgm";
|
|
26
|
+
/** Computer-only folder inside one agent, app or tool. Never synced. */
|
|
27
|
+
export declare const PRIVATE_DIR_NAME = ".private";
|
|
28
|
+
/** The three kinds of entity that live as one folder each in a user's home. */
|
|
29
|
+
export declare const ENTITY_KINDS: Readonly<{
|
|
30
|
+
readonly agent: Readonly<{
|
|
31
|
+
root: "agents";
|
|
32
|
+
identityFile: ".amalgm-agent.json";
|
|
33
|
+
}>;
|
|
34
|
+
readonly app: Readonly<{
|
|
35
|
+
root: "apps";
|
|
36
|
+
identityFile: ".amalgm-app.json";
|
|
37
|
+
}>;
|
|
38
|
+
readonly tool: Readonly<{
|
|
39
|
+
root: "toolbox";
|
|
40
|
+
identityFile: ".amalgm-tool.json";
|
|
41
|
+
}>;
|
|
42
|
+
}>;
|
|
43
|
+
export type EntityKind = keyof typeof ENTITY_KINDS;
|
|
44
|
+
/** The folders of a user's home. Nothing else sits at the top level except
|
|
45
|
+
* the manifest, the ignore file, `instructions.md` and `.amalgm/`. */
|
|
46
|
+
export declare const USER_ROOTS: readonly ["agents", "apps", "toolbox", "workspaces"];
|
|
47
|
+
export type UserRootName = typeof USER_ROOTS[number];
|
|
48
|
+
/** `~/.amalgm`: what the installer puts on a computer. Runtime state never lives here. */
|
|
49
|
+
export declare function installerHome(homeDir: string): {
|
|
50
|
+
root: string;
|
|
51
|
+
bin: string;
|
|
52
|
+
toolchains: string;
|
|
53
|
+
downloads: string;
|
|
54
|
+
cache: string;
|
|
55
|
+
setupLease: string;
|
|
56
|
+
};
|
|
57
|
+
/** The lane root for a binding: `~/amalgm`, `~/amalgm-preview` or `~/amalgm-dev/<session>`. */
|
|
58
|
+
export declare function laneRoot(homeDir: string, binding: RuntimeBinding): string;
|
|
59
|
+
/** Everything one lane keeps outside its users. */
|
|
60
|
+
export declare function laneLayout(root: string): {
|
|
61
|
+
root: string;
|
|
62
|
+
manifest: string;
|
|
63
|
+
dir: string;
|
|
64
|
+
device: string;
|
|
65
|
+
/** This installation's device key and its recovery copy. */
|
|
66
|
+
authorization: string;
|
|
67
|
+
/** The launcher's pointer to the runtime package it starts. */
|
|
68
|
+
current: string;
|
|
69
|
+
/** Unpacked runtime packages, one folder per package id. */
|
|
70
|
+
rt: string;
|
|
71
|
+
/** One OS service's files and every lease it holds. */
|
|
72
|
+
service: (serviceId: string) => string;
|
|
73
|
+
users: string;
|
|
74
|
+
user: (email: string) => string;
|
|
75
|
+
};
|
|
76
|
+
/** A user's folder name: the email, lowercased and made safe for every file
|
|
77
|
+
* system. A name longer than 40 characters is cut and given a stable suffix. */
|
|
78
|
+
export declare function userFolderName(email: string): string;
|
|
79
|
+
/** Everything in one user's home, and that user's computer-only files. */
|
|
80
|
+
export declare function userLayout(root: string): {
|
|
81
|
+
root: string;
|
|
82
|
+
manifest: string;
|
|
83
|
+
ignoreFile: string;
|
|
84
|
+
/** The user's instructions for every agent. */
|
|
85
|
+
instructions: string;
|
|
86
|
+
agents: string;
|
|
87
|
+
apps: string;
|
|
88
|
+
toolbox: string;
|
|
89
|
+
workspaces: string;
|
|
90
|
+
computer: {
|
|
91
|
+
dir: string;
|
|
92
|
+
record: string;
|
|
93
|
+
auth: string;
|
|
94
|
+
installation: string;
|
|
95
|
+
status: string;
|
|
96
|
+
sync: string;
|
|
97
|
+
/** The one credential vault. Products ask Shell; they never open it. */
|
|
98
|
+
credentials: string;
|
|
99
|
+
runtime: string;
|
|
100
|
+
runtimeToken: string;
|
|
101
|
+
workspaces: string;
|
|
102
|
+
stateEvents: string;
|
|
103
|
+
logs: string;
|
|
104
|
+
parked: string;
|
|
105
|
+
chat: string;
|
|
106
|
+
apps: string;
|
|
107
|
+
tools: string;
|
|
108
|
+
browser: string;
|
|
109
|
+
live: string;
|
|
110
|
+
};
|
|
111
|
+
};
|
|
112
|
+
export type UserLayout = ReturnType<typeof userLayout>;
|
|
113
|
+
/** One agent, app or tool folder inside the root its kind lives in. */
|
|
114
|
+
export declare function entityLayout(kind: EntityKind, root: string, folderName: string): {
|
|
115
|
+
dir: string;
|
|
116
|
+
identity: string;
|
|
117
|
+
private: string;
|
|
118
|
+
};
|
|
46
119
|
/**
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
* of leading/trailing underscores, falling back to `'local'` — kept in
|
|
51
|
-
* lockstep so legacy uuid folders resolve to the exact names they were
|
|
52
|
-
* created with. Ported once; {@link sanitizeFolderSegment} is the same
|
|
53
|
-
* function under its layout-side name.
|
|
120
|
+
* The folder name for an entity called `name`: the name itself, made safe
|
|
121
|
+
* for Windows, macOS and Linux and kept to 40 characters. A name already in
|
|
122
|
+
* `taken` (compared without case) gets "-2", "-3", ….
|
|
54
123
|
*/
|
|
55
|
-
export declare function
|
|
56
|
-
/**
|
|
57
|
-
*
|
|
58
|
-
export declare
|
|
59
|
-
/**
|
|
60
|
-
*
|
|
61
|
-
* `
|
|
62
|
-
export declare function
|
|
63
|
-
/**
|
|
64
|
-
export interface UserHomeRootDeclaration {
|
|
65
|
-
readonly key: string;
|
|
66
|
-
readonly relativePath: string;
|
|
67
|
-
}
|
|
68
|
-
/** An exact platform-managed node. Management is an exact-node fact — it
|
|
69
|
-
* deliberately does not cascade from `system/`. */
|
|
70
|
-
export interface UserHomeExactManagedDeclaration {
|
|
71
|
-
readonly key: string;
|
|
72
|
-
readonly relativePath: string;
|
|
73
|
-
readonly rootKey: string;
|
|
74
|
-
readonly toolId?: string;
|
|
75
|
-
}
|
|
76
|
-
/** What a user home contains: content roots plus the exact managed graph. */
|
|
77
|
-
export interface UserHomeDeclaration {
|
|
78
|
-
readonly roots: readonly UserHomeRootDeclaration[];
|
|
79
|
-
readonly exactManaged: readonly UserHomeExactManagedDeclaration[];
|
|
80
|
-
}
|
|
81
|
-
export interface ShippedUserHomeDeclaration extends UserHomeDeclaration {
|
|
82
|
-
readonly systemToolArtifacts: readonly UserHomeExactManagedDeclaration[];
|
|
83
|
-
}
|
|
84
|
-
/**
|
|
85
|
-
* The user-home graph the managed product ships: the seven
|
|
86
|
-
* roots, one `<key>-root` managed node per root, the home manifest at
|
|
87
|
-
* `system/home.json`, `system/defaults`, `system/policy`, and the seven
|
|
88
|
-
* system tool artifacts. These CONTENTS are PRODUCT declarations, not
|
|
89
|
-
* kernel law — the builder ({@link buildUserHomeManifest}) takes any
|
|
90
|
-
* declaration as input. The shipped set lives here only until the products
|
|
91
|
-
* register their own declarations.
|
|
92
|
-
*/
|
|
93
|
-
export declare const shippedUserHomeDeclaration: ShippedUserHomeDeclaration;
|
|
94
|
-
/** The persisted `system/home.json` contents (layout.js:137-146). */
|
|
95
|
-
export interface UserHomeManifest {
|
|
96
|
-
readonly schemaVersion: number;
|
|
97
|
-
readonly kind: 'amalgm-user-home';
|
|
98
|
-
readonly roots: readonly {
|
|
99
|
-
readonly key: string;
|
|
100
|
-
readonly path: string;
|
|
101
|
-
}[];
|
|
102
|
-
readonly exactManaged: readonly {
|
|
103
|
-
readonly key: string;
|
|
104
|
-
readonly path: string;
|
|
105
|
-
readonly scope: 'exact';
|
|
106
|
-
}[];
|
|
107
|
-
}
|
|
108
|
-
/**
|
|
109
|
-
* The user-home manifest for a declaration (engine ensureUserHome's
|
|
110
|
-
* `manifestContents`, layout.js:137-146): the current user-home schema, kind
|
|
111
|
-
* `amalgm-user-home`, and the declaration's entries with each
|
|
112
|
-
* `relativePath` published under the key name `path` — relative, so the
|
|
113
|
-
* manifest survives a moved or renamed user folder — and every managed
|
|
114
|
-
* node stamped `scope: 'exact'`.
|
|
115
|
-
*/
|
|
116
|
-
export declare function buildUserHomeManifest(declaration: UserHomeDeclaration): UserHomeManifest;
|
|
117
|
-
/** `.amalgm-root.json` — installation identity plus the user-folder index
|
|
118
|
-
* (a cache; user-manifest scans stay authoritative). */
|
|
124
|
+
export declare function entityFolderName(name: string, taken?: Iterable<string>): string;
|
|
125
|
+
/** Where a deleted entity's `.private` folder is kept: `<parked>/<kind>/<id>`,
|
|
126
|
+
* with `parked` from {@link userLayout}'s `computer.parked`. */
|
|
127
|
+
export declare function parkedDir(parked: string, kind: EntityKind, id: string): string;
|
|
128
|
+
/** True when a path inside a user's home is computer-only: any segment is
|
|
129
|
+
* `.amalgm` or `.private`, in any letter case (macOS and Windows disks treat
|
|
130
|
+
* `.Private` as the same folder). Such paths are never synced, watched or served. */
|
|
131
|
+
export declare function isLocalOnlyPath(relativePath: string): boolean;
|
|
132
|
+
/** `.amalgm-root.json`: the lane's installation identity. */
|
|
119
133
|
export interface RootManifest {
|
|
120
134
|
readonly schemaVersion: number;
|
|
121
135
|
readonly installationId: string;
|
|
122
136
|
readonly createdAt: string;
|
|
123
|
-
readonly users: Record<string, unknown>;
|
|
124
137
|
}
|
|
125
|
-
/**
|
|
126
|
-
*
|
|
127
|
-
* layout.js:234-245, minus the write): an existing manifest that already
|
|
128
|
-
* carries an installationId is returned untouched — installation identity
|
|
129
|
-
* is minted once, never re-rolled — otherwise a fresh manifest is built,
|
|
130
|
-
* preserving any partial `createdAt`/`users`, with an 8-byte hex
|
|
131
|
-
* installationId from the injected randomness.
|
|
132
|
-
*/
|
|
138
|
+
/** The lane manifest to keep: an existing current one untouched (identity is
|
|
139
|
+
* minted once), otherwise a new one. */
|
|
133
140
|
export declare function buildRootManifest(existing: Partial<RootManifest> | null | undefined, ports: ClockIsoPort & RandomHexPort): RootManifest;
|
|
134
|
-
/**
|
|
141
|
+
/** Refuses a lane made by an older Amalgm. There is no migration. */
|
|
142
|
+
export declare function requireCurrentLayout(manifest: {
|
|
143
|
+
readonly schemaVersion?: unknown;
|
|
144
|
+
} | null | undefined): void;
|
|
145
|
+
/** `.amalgm-user.json`: the stable identity of a user folder. */
|
|
135
146
|
export interface UserManifest {
|
|
136
147
|
readonly schemaVersion: number;
|
|
137
148
|
readonly userId: string;
|
|
138
149
|
readonly canonicalEmail: string;
|
|
139
|
-
readonly emailHistory: readonly
|
|
150
|
+
readonly emailHistory: readonly string[];
|
|
140
151
|
readonly createdAt: string;
|
|
141
152
|
readonly updatedAt: string;
|
|
142
153
|
}
|
|
143
|
-
/**
|
|
144
|
-
*
|
|
145
|
-
* minus the write): userId trimmed, canonicalEmail lowercased with the
|
|
146
|
-
* existing email as fallback, and emailHistory APPEND-ONLY — a new
|
|
147
|
-
* canonical email joins the history, nothing ever leaves it, so every name
|
|
148
|
-
* this user has worn stays resolvable. `createdAt` is preserved;
|
|
149
|
-
* `updatedAt` is stamped now.
|
|
150
|
-
*/
|
|
154
|
+
/** The next user manifest. Email history only grows, so every email this
|
|
155
|
+
* user has had still finds the folder. */
|
|
151
156
|
export declare function buildUserManifest(identity: {
|
|
152
157
|
readonly userId: string;
|
|
153
|
-
readonly email?:
|
|
158
|
+
readonly email?: string | null;
|
|
154
159
|
}, existing: Partial<UserManifest> | null | undefined, ports: ClockIsoPort): UserManifest;
|
|
155
|
-
/** THE path join of this grammar: segments glued with `/`, nothing
|
|
156
|
-
* normalized (see the header's deliberate-deviation note on separators).
|
|
157
|
-
* Exported so callers composing onto these paths use the same law instead
|
|
158
|
-
* of reaching for `node:path`, which axiom 6 forbids them anyway. */
|
|
159
|
-
export declare function joinPathSegments(...segments: string[]): string;
|
|
160
|
-
/**
|
|
161
|
-
* The name-derived user dir: `<homeDir>/users/<sanitized scope>` (engine
|
|
162
|
-
* scopedAmalgmDir, runtime-identity.js:137-142). DELIBERATE DEVIATION: the
|
|
163
|
-
* engine signature takes a third `label` parameter it asserts and then
|
|
164
|
-
* IGNORES — vestigial since manifest identity won over label-scoped
|
|
165
|
-
* folders — so the honest signature drops it. This is only the fallback
|
|
166
|
-
* path grammar: manifest-based resolution (find-by-userId across
|
|
167
|
-
* `.amalgm-user.json` files) reads the filesystem and stays host-side.
|
|
168
|
-
*/
|
|
169
|
-
export declare function scopedAmalgmDir(homeDir: string, userScope: unknown): string;
|
|
170
|
-
/** The tracked ignore policy at the root of one user ground. */
|
|
171
|
-
export declare function userIgnoreFile(userDir: string): string;
|
|
172
|
-
/** The reserved, unregistered control namespace for one user. */
|
|
173
|
-
export declare function userControlDir(userDir: string): string;
|
|
174
|
-
/** Machine-local state for one physical device under one user's home. */
|
|
175
|
-
export declare function userMachineDir(userDir: string, deviceId: unknown): string;
|
|
176
|
-
/** Files/Live's machine-local databases and immutable content cache. */
|
|
177
|
-
export declare function liveMachineStateDir(userDir: string, deviceId: unknown): string;
|
|
178
|
-
/** Per-label runtime state inside the reserved per-device control namespace.
|
|
179
|
-
* The label must be one of the three — junk never names a state dir. */
|
|
180
|
-
export declare function runtimeStateDir(userDir: string, deviceId: unknown, label: string): string;
|
|
181
|
-
/** `runtime-state.json` inside a runtime state dir (runtime-paths.js:88-90). */
|
|
182
|
-
export declare function runtimeStateFile(stateDir: string): string;
|
|
183
|
-
/** `runtime-token.json` inside a runtime state dir (runtime-paths.js:92-94). */
|
|
184
|
-
export declare function runtimeTokenFile(stateDir: string): string;
|
|
185
|
-
/** `logs/` inside a runtime state dir (runtime-paths.js:96-98). */
|
|
186
|
-
export declare function runtimeLogDir(stateDir: string): string;
|
|
187
|
-
/** `computer.json` — the public computer record beside a state or user dir
|
|
188
|
-
* (engine config.js:37-40, proxy-token-store.js:25-28). */
|
|
189
|
-
export declare function computerRecordFile(dir: string): string;
|
|
190
|
-
/** `auth.json` — the secret auth envelope beside a state or user dir
|
|
191
|
-
* (engine config.js:37-40, proxy-token-store.js:25-28). */
|
|
192
|
-
export declare function computerAuthFile(dir: string): string;
|
|
193
|
-
/**
|
|
194
|
-
* A primitive root under the user dir (layout.js:414-419). Only the seven
|
|
195
|
-
* declared namespaces exist; the refusal string is the ratified text.
|
|
196
|
-
*/
|
|
197
|
-
export declare function userPrimitiveRoot(userDir: string, kind: string): string;
|
|
198
160
|
//# sourceMappingURL=layout.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"layout.d.ts","sourceRoot":"","sources":["../../src/identity/layout.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"layout.d.ts","sourceRoot":"","sources":["../../src/identity/layout.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAuB,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAChF,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAE9D,uFAAuF;AACvF,eAAO,MAAM,cAAc,IAAI,CAAC;AAEhC,eAAO,MAAM,kBAAkB,sBAAsB,CAAC;AACtD,eAAO,MAAM,kBAAkB,sBAAsB,CAAC;AACtD,eAAO,MAAM,qBAAqB,kBAAkB,CAAC;AAErD,8FAA8F;AAC9F,eAAO,MAAM,cAAc,YAAY,CAAC;AAExC,wEAAwE;AACxE,eAAO,MAAM,gBAAgB,aAAa,CAAC;AAE3C,+EAA+E;AAC/E,eAAO,MAAM,YAAY;;;;;;;;;;;;;EAId,CAAC;AAEZ,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,YAAY,CAAC;AAEnD;sEACsE;AACtE,eAAO,MAAM,UAAU,sDAAsE,CAAC;AAE9F,MAAM,MAAM,YAAY,GAAG,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC;AASrD,0FAA0F;AAC1F,wBAA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