agentlink-sh 0.26.0 → 0.26.1
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 +4 -24
- package/dist/index.js +2 -16
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,28 +6,10 @@ Teach AI agents the right way to build on Supabase.
|
|
|
6
6
|
|
|
7
7
|
## Install & Run
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
Install cli globally.
|
|
10
10
|
|
|
11
11
|
```bash
|
|
12
|
-
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
### Linux
|
|
16
|
-
|
|
17
|
-
```bash
|
|
18
|
-
wget -qO- https://agentlink.sh/install | sh
|
|
19
|
-
```
|
|
20
|
-
|
|
21
|
-
### Windows (PowerShell)
|
|
22
|
-
|
|
23
|
-
```powershell
|
|
24
|
-
irm https://agentlink.sh/install.ps1 | iex
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
### npx (any platform with Node.js 18+)
|
|
28
|
-
|
|
29
|
-
```bash
|
|
30
|
-
npx agentlink-sh@latest
|
|
12
|
+
npm i -g agentlink-sh@latest
|
|
31
13
|
```
|
|
32
14
|
|
|
33
15
|
Or run directly with npx (requires Node.js 18+):
|
|
@@ -36,8 +18,6 @@ Or run directly with npx (requires Node.js 18+):
|
|
|
36
18
|
npx agentlink-sh@latest
|
|
37
19
|
```
|
|
38
20
|
|
|
39
|
-
The install scripts automatically detect your OS, install Node.js if needed, and set up the CLI globally.
|
|
40
|
-
|
|
41
21
|
## Quick start
|
|
42
22
|
|
|
43
23
|
```bash
|
|
@@ -312,7 +292,7 @@ Apply one or more server-side config sections to a cloud env. The three subsyste
|
|
|
312
292
|
|
|
313
293
|
| Subcommand | What it does |
|
|
314
294
|
|-----------|--------------|
|
|
315
|
-
| `secrets` | Seed Vault (`SUPABASE_URL` / `SUPABASE_PUBLISHABLE_KEY` / `SUPABASE_SECRET_KEY`)
|
|
295
|
+
| `secrets` | Seed Vault (`SUPABASE_URL` / `SUPABASE_PUBLISHABLE_KEY` / `SUPABASE_SECRET_KEY`). Edge functions read the platform-injected `SUPABASE_*` env vars directly — no `SB_*` mirror. |
|
|
316
296
|
| `db` | PATCH PostgREST to expose the `api` schema. |
|
|
317
297
|
| `auth` | PATCH auth config (hooks + signup settings). |
|
|
318
298
|
| `all` | Run all three in order. |
|
|
@@ -392,7 +372,7 @@ agentlink db rebuild # Wipes migrations, re-applies schemas, create
|
|
|
392
372
|
|
|
393
373
|
The scaffold runs a multi-step process:
|
|
394
374
|
|
|
395
|
-
1. **Prerequisites** —
|
|
375
|
+
1. **Prerequisites** — Supabase CLI and pgdelta come bundled with `agentlink-sh` (no manual install). Local mode also checks for psql and Docker.
|
|
396
376
|
2. **Configure files** — Writes template files, `config.toml`, and `.env.local`
|
|
397
377
|
3. **Start Supabase** — Starts locally (Docker) or creates a Cloud project
|
|
398
378
|
4. **Read config** — Reads Supabase API keys and connection info
|
package/dist/index.js
CHANGED
|
@@ -2260,20 +2260,6 @@ async function applyVaultSecrets(opts) {
|
|
|
2260
2260
|
opts.projectRef
|
|
2261
2261
|
);
|
|
2262
2262
|
});
|
|
2263
|
-
await step(`${prefix}Mirroring keys to edge-function secrets (SB_*)`, async () => {
|
|
2264
|
-
const existing = new Set(await listSecrets(opts.projectRef));
|
|
2265
|
-
const candidates = {
|
|
2266
|
-
SB_URL: opts.apiUrl,
|
|
2267
|
-
SB_PUBLISHABLE_KEY: opts.publishableKey,
|
|
2268
|
-
SB_SECRET_KEY: opts.secretKey
|
|
2269
|
-
};
|
|
2270
|
-
const toSet = {};
|
|
2271
|
-
for (const [k, v] of Object.entries(candidates)) {
|
|
2272
|
-
if (!existing.has(k)) toSet[k] = v;
|
|
2273
|
-
}
|
|
2274
|
-
if (Object.keys(toSet).length === 0) return;
|
|
2275
|
-
await setSecrets(opts.projectRef, toSet);
|
|
2276
|
-
});
|
|
2277
2263
|
}
|
|
2278
2264
|
async function applyPostgrestConfig(opts) {
|
|
2279
2265
|
const prefix = opts.titlePrefix ? `${opts.titlePrefix} \u2014 ` : "";
|
|
@@ -3792,7 +3778,7 @@ async function envConfig(subcommand, cwd, opts = {}) {
|
|
|
3792
3778
|
theme,
|
|
3793
3779
|
choices: [
|
|
3794
3780
|
{ name: "All (secrets + db + auth)", value: "all" },
|
|
3795
|
-
{ name: "Secrets \u2014 Vault
|
|
3781
|
+
{ name: "Secrets \u2014 Postgres Vault (SUPABASE_URL / publishable / secret)", value: "secrets" },
|
|
3796
3782
|
{ name: "DB \u2014 expose api schema via PostgREST", value: "db" },
|
|
3797
3783
|
{ name: "Auth \u2014 hooks + signup settings", value: "auth" }
|
|
3798
3784
|
]
|
|
@@ -7439,7 +7425,7 @@ ${red("Error:")} ${err.message}`);
|
|
|
7439
7425
|
process.exit(1);
|
|
7440
7426
|
}
|
|
7441
7427
|
});
|
|
7442
|
-
env.command("config [subcommand] [name]").description("Apply one or more config sections to a cloud env. Subcommand: secrets (Vault
|
|
7428
|
+
env.command("config [subcommand] [name]").description("Apply one or more config sections to a cloud env. Subcommand: secrets (Vault) | db (expose api schema via PostgREST) | auth (hooks + signup settings) | all. Env: dev | prod (positional, or --env flag for CI). Omit either for an interactive picker. Idempotent; works on bare projects. Replaces the removed `config apply` command.").option("--env <name>", "Target cloud environment (same as the trailing positional)").option("-y, --yes", "Skip the prod confirmation prompt (for CI)").option("--non-interactive", "Error instead of prompting").option("--debug", "Write debug log to agentlink-debug.log").action(async (subcommand, name, opts) => {
|
|
7443
7429
|
if (opts.debug) initLog(true);
|
|
7444
7430
|
try {
|
|
7445
7431
|
const validSubs = ["secrets", "db", "auth", "all"];
|