@specific.dev/cli 0.1.108 → 0.1.110
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/admin/404/index.html +1 -1
- package/dist/admin/404.html +1 -1
- package/dist/admin/__next.!KGRlZmF1bHQp.__PAGE__.txt +1 -1
- package/dist/admin/__next.!KGRlZmF1bHQp.txt +1 -1
- package/dist/admin/__next._full.txt +1 -1
- package/dist/admin/__next._head.txt +1 -1
- package/dist/admin/__next._index.txt +1 -1
- package/dist/admin/__next._tree.txt +1 -1
- package/dist/admin/_not-found/__next._full.txt +1 -1
- package/dist/admin/_not-found/__next._head.txt +1 -1
- package/dist/admin/_not-found/__next._index.txt +1 -1
- package/dist/admin/_not-found/__next._not-found.__PAGE__.txt +1 -1
- package/dist/admin/_not-found/__next._not-found.txt +1 -1
- package/dist/admin/_not-found/__next._tree.txt +1 -1
- package/dist/admin/_not-found/index.html +1 -1
- package/dist/admin/_not-found/index.txt +1 -1
- package/dist/admin/databases/__next.!KGRlZmF1bHQp.databases.__PAGE__.txt +1 -1
- package/dist/admin/databases/__next.!KGRlZmF1bHQp.databases.txt +1 -1
- package/dist/admin/databases/__next.!KGRlZmF1bHQp.txt +1 -1
- package/dist/admin/databases/__next._full.txt +1 -1
- package/dist/admin/databases/__next._head.txt +1 -1
- package/dist/admin/databases/__next._index.txt +1 -1
- package/dist/admin/databases/__next._tree.txt +1 -1
- package/dist/admin/databases/index.html +1 -1
- package/dist/admin/databases/index.txt +1 -1
- package/dist/admin/fullscreen/__next._full.txt +1 -1
- package/dist/admin/fullscreen/__next._head.txt +1 -1
- package/dist/admin/fullscreen/__next._index.txt +1 -1
- package/dist/admin/fullscreen/__next._tree.txt +1 -1
- package/dist/admin/fullscreen/__next.fullscreen.__PAGE__.txt +1 -1
- package/dist/admin/fullscreen/__next.fullscreen.txt +1 -1
- package/dist/admin/fullscreen/databases/__next._full.txt +1 -1
- package/dist/admin/fullscreen/databases/__next._head.txt +1 -1
- package/dist/admin/fullscreen/databases/__next._index.txt +1 -1
- package/dist/admin/fullscreen/databases/__next._tree.txt +1 -1
- package/dist/admin/fullscreen/databases/__next.fullscreen.databases.__PAGE__.txt +1 -1
- package/dist/admin/fullscreen/databases/__next.fullscreen.databases.txt +1 -1
- package/dist/admin/fullscreen/databases/__next.fullscreen.txt +1 -1
- package/dist/admin/fullscreen/databases/index.html +1 -1
- package/dist/admin/fullscreen/databases/index.txt +1 -1
- package/dist/admin/fullscreen/index.html +1 -1
- package/dist/admin/fullscreen/index.txt +1 -1
- package/dist/admin/index.html +1 -1
- package/dist/admin/index.txt +1 -1
- package/dist/admin/mail/__next.!KGRlZmF1bHQp.mail.__PAGE__.txt +1 -1
- package/dist/admin/mail/__next.!KGRlZmF1bHQp.mail.txt +1 -1
- package/dist/admin/mail/__next.!KGRlZmF1bHQp.txt +1 -1
- package/dist/admin/mail/__next._full.txt +1 -1
- package/dist/admin/mail/__next._head.txt +1 -1
- package/dist/admin/mail/__next._index.txt +1 -1
- package/dist/admin/mail/__next._tree.txt +1 -1
- package/dist/admin/mail/index.html +1 -1
- package/dist/admin/mail/index.txt +1 -1
- package/dist/admin/workflows/__next.!KGRlZmF1bHQp.txt +1 -1
- package/dist/admin/workflows/__next.!KGRlZmF1bHQp.workflows.__PAGE__.txt +1 -1
- package/dist/admin/workflows/__next.!KGRlZmF1bHQp.workflows.txt +1 -1
- package/dist/admin/workflows/__next._full.txt +1 -1
- package/dist/admin/workflows/__next._head.txt +1 -1
- package/dist/admin/workflows/__next._index.txt +1 -1
- package/dist/admin/workflows/__next._tree.txt +1 -1
- package/dist/admin/workflows/index.html +1 -1
- package/dist/admin/workflows/index.txt +1 -1
- package/dist/cli.js +60 -15
- package/dist/docs/postgres/reshape/actions.md +16 -20
- package/package.json +1 -1
- /package/dist/admin/_next/static/{-uB2tvCTW06hUMOZfRURZ → XxrIhY0Ur2j5au9Vfy8af}/_buildManifest.js +0 -0
- /package/dist/admin/_next/static/{-uB2tvCTW06hUMOZfRURZ → XxrIhY0Ur2j5au9Vfy8af}/_clientMiddlewareManifest.json +0 -0
- /package/dist/admin/_next/static/{-uB2tvCTW06hUMOZfRURZ → XxrIhY0Ur2j5au9Vfy8af}/_ssgManifest.js +0 -0
package/dist/cli.js
CHANGED
|
@@ -369255,7 +369255,18 @@ async function startPostgres(pg, port, dataDir, onProgress) {
|
|
|
369255
369255
|
}
|
|
369256
369256
|
);
|
|
369257
369257
|
pipeProcess("postgres", postgres);
|
|
369258
|
-
await
|
|
369258
|
+
await Promise.race([
|
|
369259
|
+
waitForTcpPort(host, port),
|
|
369260
|
+
new Promise((_, reject) => {
|
|
369261
|
+
postgres.once("exit", (code, signal) => {
|
|
369262
|
+
reject(
|
|
369263
|
+
new Error(
|
|
369264
|
+
`PostgreSQL "${pg.name}" exited during startup (code ${code}, signal ${signal}). Port ${port} may already be in use by another process.`
|
|
369265
|
+
)
|
|
369266
|
+
);
|
|
369267
|
+
});
|
|
369268
|
+
})
|
|
369269
|
+
]);
|
|
369259
369270
|
return {
|
|
369260
369271
|
name: pg.name,
|
|
369261
369272
|
type: "postgres",
|
|
@@ -371433,7 +371444,9 @@ var BlockPortAllocator = class _BlockPortAllocator {
|
|
|
371433
371444
|
static async create() {
|
|
371434
371445
|
for (let i = 0; i < MAX_BLOCKS; i++) {
|
|
371435
371446
|
const base = FIRST_BLOCK_START + i * BLOCK_SIZE;
|
|
371436
|
-
|
|
371447
|
+
const ports = Array.from({ length: BLOCK_SIZE }, (_, j) => base + j);
|
|
371448
|
+
const results = await Promise.all(ports.map(isPortAvailable));
|
|
371449
|
+
if (results.every(Boolean)) {
|
|
371437
371450
|
return new _BlockPortAllocator(base);
|
|
371438
371451
|
}
|
|
371439
371452
|
}
|
|
@@ -373187,7 +373200,7 @@ function trackEvent(event, properties) {
|
|
|
373187
373200
|
event,
|
|
373188
373201
|
properties: {
|
|
373189
373202
|
...properties,
|
|
373190
|
-
cli_version: "0.1.
|
|
373203
|
+
cli_version: "0.1.110",
|
|
373191
373204
|
platform: process.platform,
|
|
373192
373205
|
node_version: process.version,
|
|
373193
373206
|
project_id: getProjectId()
|
|
@@ -373506,6 +373519,7 @@ Valid agents: ${VALID_AGENT_IDS.join(", ")}`
|
|
|
373506
373519
|
|
|
373507
373520
|
// src/commands/docs.tsx
|
|
373508
373521
|
import { readFileSync as readFileSync9, existsSync as existsSync17 } from "fs";
|
|
373522
|
+
import { spawn as spawn6 } from "child_process";
|
|
373509
373523
|
import { join as join19, dirname as dirname8 } from "path";
|
|
373510
373524
|
import { fileURLToPath as fileURLToPath3 } from "url";
|
|
373511
373525
|
|
|
@@ -373565,8 +373579,12 @@ function saveBetas(enabled, projectDir) {
|
|
|
373565
373579
|
var __dirname3 = dirname8(fileURLToPath3(import.meta.url));
|
|
373566
373580
|
var docsDir = join19(__dirname3, "docs");
|
|
373567
373581
|
var _embeddedDocs = null;
|
|
373568
|
-
|
|
373569
|
-
|
|
373582
|
+
var RESHAPE_DOCS_PREFIX = "postgres/reshape/";
|
|
373583
|
+
async function docsCommand(path27) {
|
|
373584
|
+
let content = resolveDocContent(path27);
|
|
373585
|
+
if (!content && path27) {
|
|
373586
|
+
content = await resolveReshapeDoc(path27);
|
|
373587
|
+
}
|
|
373570
373588
|
if (!content) {
|
|
373571
373589
|
console.error(
|
|
373572
373590
|
`Documentation not found: ${path27 || "index"}
|
|
@@ -373579,6 +373597,33 @@ Run 'specific docs' to see available topics.`
|
|
|
373579
373597
|
const filtered = filterBetaTags(content, enabledBetas);
|
|
373580
373598
|
console.log(filtered);
|
|
373581
373599
|
}
|
|
373600
|
+
async function resolveReshapeDoc(path27) {
|
|
373601
|
+
const normalized = path27.replace(/^\/+|\/+$/g, "");
|
|
373602
|
+
if (!normalized.startsWith(RESHAPE_DOCS_PREFIX)) return null;
|
|
373603
|
+
const reshapePath = "/" + normalized.slice(RESHAPE_DOCS_PREFIX.length);
|
|
373604
|
+
try {
|
|
373605
|
+
const binary = await ensureBinary(reshapeBinary);
|
|
373606
|
+
const reshapeExe = binary.executables["reshape"];
|
|
373607
|
+
const output = await new Promise((resolve9) => {
|
|
373608
|
+
const child = spawn6(reshapeExe, ["docs", reshapePath], {
|
|
373609
|
+
stdio: ["ignore", "pipe", "ignore"]
|
|
373610
|
+
});
|
|
373611
|
+
const chunks = [];
|
|
373612
|
+
child.stdout.on("data", (chunk) => chunks.push(chunk));
|
|
373613
|
+
child.on("error", () => resolve9(null));
|
|
373614
|
+
child.on("close", (code) => {
|
|
373615
|
+
if (code === 0 && chunks.length > 0) {
|
|
373616
|
+
resolve9(Buffer.concat(chunks).toString("utf-8"));
|
|
373617
|
+
} else {
|
|
373618
|
+
resolve9(null);
|
|
373619
|
+
}
|
|
373620
|
+
});
|
|
373621
|
+
});
|
|
373622
|
+
if (output) return output;
|
|
373623
|
+
} catch {
|
|
373624
|
+
}
|
|
373625
|
+
return null;
|
|
373626
|
+
}
|
|
373582
373627
|
function filterBetaTags(content, enabledBetas) {
|
|
373583
373628
|
return content.replace(
|
|
373584
373629
|
/<!-- beta:(\w[\w-]*) -->\n?([\s\S]*?)<!-- \/beta:\1 -->\n?/g,
|
|
@@ -376034,7 +376079,7 @@ async function deployCommand(options2) {
|
|
|
376034
376079
|
}
|
|
376035
376080
|
|
|
376036
376081
|
// src/commands/exec.tsx
|
|
376037
|
-
import { spawn as
|
|
376082
|
+
import { spawn as spawn7 } from "child_process";
|
|
376038
376083
|
import * as fs23 from "fs";
|
|
376039
376084
|
import * as path21 from "path";
|
|
376040
376085
|
function startSpinner(text) {
|
|
@@ -376229,7 +376274,7 @@ async function execCommand(serviceName, command, instanceKey = "default") {
|
|
|
376229
376274
|
}
|
|
376230
376275
|
}
|
|
376231
376276
|
spinner?.stop();
|
|
376232
|
-
child =
|
|
376277
|
+
child = spawn7(command[0], command.slice(1), {
|
|
376233
376278
|
cwd: effectiveCwd,
|
|
376234
376279
|
env: {
|
|
376235
376280
|
...process.env,
|
|
@@ -376253,7 +376298,7 @@ async function execCommand(serviceName, command, instanceKey = "default") {
|
|
|
376253
376298
|
}
|
|
376254
376299
|
|
|
376255
376300
|
// src/commands/psql.tsx
|
|
376256
|
-
import { spawn as
|
|
376301
|
+
import { spawn as spawn8 } from "child_process";
|
|
376257
376302
|
import * as fs24 from "fs";
|
|
376258
376303
|
import * as path22 from "path";
|
|
376259
376304
|
async function psqlCommand(databaseName, instanceKey = "default", extraArgs = []) {
|
|
@@ -376377,7 +376422,7 @@ async function psqlCommand(databaseName, instanceKey = "default", extraArgs = []
|
|
|
376377
376422
|
};
|
|
376378
376423
|
process.on("SIGINT", () => handleSignal("SIGINT"));
|
|
376379
376424
|
process.on("SIGTERM", () => handleSignal("SIGTERM"));
|
|
376380
|
-
child =
|
|
376425
|
+
child = spawn8(psqlPath, ["-h", dbState.host, "-p", String(dbState.port), "-U", dbState.user, "-d", dbState.dbName, ...extraArgs], {
|
|
376381
376426
|
cwd: process.cwd(),
|
|
376382
376427
|
env: {
|
|
376383
376428
|
...process.env,
|
|
@@ -376402,7 +376447,7 @@ async function psqlCommand(databaseName, instanceKey = "default", extraArgs = []
|
|
|
376402
376447
|
}
|
|
376403
376448
|
|
|
376404
376449
|
// src/commands/reshape.tsx
|
|
376405
|
-
import { spawn as
|
|
376450
|
+
import { spawn as spawn9 } from "child_process";
|
|
376406
376451
|
import * as fs25 from "fs";
|
|
376407
376452
|
import * as path23 from "path";
|
|
376408
376453
|
var VALID_ACTIONS = ["start", "complete", "status", "abort", "check"];
|
|
@@ -376589,7 +376634,7 @@ async function reshapeCommand(action, databaseName, instanceKey = "default") {
|
|
|
376589
376634
|
};
|
|
376590
376635
|
process.on("SIGINT", () => handleSignal("SIGINT"));
|
|
376591
376636
|
process.on("SIGTERM", () => handleSignal("SIGTERM"));
|
|
376592
|
-
child =
|
|
376637
|
+
child = spawn9(reshapePath, reshapeArgs, {
|
|
376593
376638
|
cwd: process.cwd(),
|
|
376594
376639
|
env: {
|
|
376595
376640
|
...process.env,
|
|
@@ -376866,7 +376911,7 @@ function compareVersions(a, b) {
|
|
|
376866
376911
|
return 0;
|
|
376867
376912
|
}
|
|
376868
376913
|
async function checkForUpdate() {
|
|
376869
|
-
const currentVersion = "0.1.
|
|
376914
|
+
const currentVersion = "0.1.110";
|
|
376870
376915
|
const response = await fetch(`${BINARIES_BASE_URL}/latest?t=${Date.now()}`);
|
|
376871
376916
|
if (!response.ok) {
|
|
376872
376917
|
throw new Error(`Failed to check for updates: HTTP ${response.status}`);
|
|
@@ -376916,7 +376961,7 @@ async function performUpdate(version, onProgress) {
|
|
|
376916
376961
|
}
|
|
376917
376962
|
|
|
376918
376963
|
// src/lib/background-update.ts
|
|
376919
|
-
import { spawn as
|
|
376964
|
+
import { spawn as spawn10 } from "child_process";
|
|
376920
376965
|
import * as fs28 from "fs";
|
|
376921
376966
|
import * as path26 from "path";
|
|
376922
376967
|
import * as os6 from "os";
|
|
@@ -376945,7 +376990,7 @@ function maybeStartBackgroundUpdate() {
|
|
|
376945
376990
|
if (process.env.SPECIFIC_BACKGROUND_UPDATE === "1") return;
|
|
376946
376991
|
if (isRateLimited()) return;
|
|
376947
376992
|
if (!isBinaryWritable()) return;
|
|
376948
|
-
const child =
|
|
376993
|
+
const child = spawn10(process.execPath, [], {
|
|
376949
376994
|
detached: true,
|
|
376950
376995
|
stdio: "ignore",
|
|
376951
376996
|
env: {
|
|
@@ -377134,7 +377179,7 @@ async function projectListCommand() {
|
|
|
377134
377179
|
var program = new Command();
|
|
377135
377180
|
var env = "production";
|
|
377136
377181
|
var envLabel = env !== "production" ? `[${env.toUpperCase()}] ` : "";
|
|
377137
|
-
program.name("specific").description(`${envLabel}Infrastructure-as-code for coding agents`).version("0.1.
|
|
377182
|
+
program.name("specific").description(`${envLabel}Infrastructure-as-code for coding agents`).version("0.1.110").enablePositionalOptions();
|
|
377138
377183
|
program.command("init").description("Initialize project for use with a coding agent").option("--agent <name...>", "Agents to configure (cursor, claude, codex, other)").addHelpText("after", `
|
|
377139
377184
|
Examples:
|
|
377140
377185
|
$ specific init
|
|
@@ -23,27 +23,23 @@ Reshape supports many different actions for modifying your database schema:
|
|
|
23
23
|
|
|
24
24
|
## Action Documentation
|
|
25
25
|
|
|
26
|
-
For detailed documentation on each action including all available options and examples
|
|
26
|
+
For detailed documentation on each action including all available options and examples:
|
|
27
27
|
|
|
28
28
|
```bash
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
reshape docs /actions/remove-foreign-key
|
|
44
|
-
reshape docs /actions/rename-table
|
|
45
|
-
reshape docs /actions/remove-table
|
|
46
|
-
reshape docs /actions/custom
|
|
29
|
+
specific docs /postgres/reshape/actions/create-table
|
|
30
|
+
specific docs /postgres/reshape/actions/add-column
|
|
31
|
+
specific docs /postgres/reshape/actions/alter-column
|
|
32
|
+
specific docs /postgres/reshape/actions/remove-column
|
|
33
|
+
specific docs /postgres/reshape/actions/create-enum
|
|
34
|
+
specific docs /postgres/reshape/actions/alter-enum
|
|
35
|
+
specific docs /postgres/reshape/actions/remove-enum
|
|
36
|
+
specific docs /postgres/reshape/actions/add-index
|
|
37
|
+
specific docs /postgres/reshape/actions/remove-index
|
|
38
|
+
specific docs /postgres/reshape/actions/add-foreign-key
|
|
39
|
+
specific docs /postgres/reshape/actions/remove-foreign-key
|
|
40
|
+
specific docs /postgres/reshape/actions/rename-table
|
|
41
|
+
specific docs /postgres/reshape/actions/remove-table
|
|
42
|
+
specific docs /postgres/reshape/actions/custom
|
|
47
43
|
```
|
|
48
44
|
|
|
49
45
|
## Example Migration
|
|
@@ -85,4 +81,4 @@ unique = true
|
|
|
85
81
|
|
|
86
82
|
Related topics:
|
|
87
83
|
- Run `specific docs /postgres/reshape` for general Reshape documentation
|
|
88
|
-
- Run `
|
|
84
|
+
- Run `specific docs /postgres/reshape/actions/{ACTION}` for detailed action documentation
|
package/package.json
CHANGED
/package/dist/admin/_next/static/{-uB2tvCTW06hUMOZfRURZ → XxrIhY0Ur2j5au9Vfy8af}/_buildManifest.js
RENAMED
|
File without changes
|
|
File without changes
|
/package/dist/admin/_next/static/{-uB2tvCTW06hUMOZfRURZ → XxrIhY0Ur2j5au9Vfy8af}/_ssgManifest.js
RENAMED
|
File without changes
|