Versions 85 to 86
Lines 21–31 at 86 (were 21–26 at 85)
2222 /** A reader folder (abso join --reader, #37): it reads everything and records nothing; the server refuses its records too. */
25+ * A visitor folder (abso join <project> --reader with no sign-in, for a public project): it reads through the
26+ * routes anyone can read and sends no credential. It has no agent; its config holds server, project and this.
2530
Lines 49–61 at 86 (were 44–49 at 85)
4449
4550export function readConfig(root: string, env: Readonly<Record<string, string | undefined>> = process.env): Config {
54+ if (typeof raw[key] !== "string" || raw[key] === "") throw new Error(`${configPath(root)} has no "${key}"`);
56+ // No token and no key, whatever the environment or the folder holds: a visitor sends no credential.
4860 if (typeof raw[key] !== "string" || raw[key] === "") throw new Error(`${configPath(root)} has no "${key}"`);
Lines 70–84 at 86 (were 58–63 at 85)
6072
73+/** Whether the folder is a visitor's: it reads signed out and sends no credential. Read straight from its config. */
76+ return (JSON.parse(readFileSync(configPath(root), "utf8")) as { visitor?: unknown }).visitor === true;
81+
6182/** Whether the folder is a reader (#37): records nothing. Read straight from its config, for the paths that only need this. */
Lines 226–236 at 86 (were 205–215 at 85)
205226
208− const { server, project, agent, follow, reader } = settings;
209− writeFileSync(
210− configPath(root),
211− `${JSON.stringify({ server, project, agent, ...(follow ? { follow } : {}), ...(reader ? { reader: true } : {}) }, null, 2)}\n`,
212− );
232+ : { server, project, agent, ...(follow ? { follow } : {}), ...(reader ? { reader: true } : {}) };
215236
- MCP
- compare on this site's /mcp
- CLI
- abso diff 85 86 client/src/config.ts --json
- JSON
- /christopher/abso-core/compare/85..86?file=client%2Fsrc%2Fconfig.ts&format=json