cassian-cli 0.3.8 → 0.3.10
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/commands/status.js +1 -1
- package/dist/commands/sync.js +9 -0
- package/dist/lib/push.js +10 -0
- package/dist/lib/watcher.js +10 -1
- package/dist/types.d.ts +1 -0
- package/package.json +1 -1
package/dist/commands/status.js
CHANGED
|
@@ -18,7 +18,7 @@ export async function status() {
|
|
|
18
18
|
}
|
|
19
19
|
else {
|
|
20
20
|
for (const inst of instances) {
|
|
21
|
-
const gpus = `${inst.gpu_count}x ${
|
|
21
|
+
const gpus = `${inst.gpu_count}x ${(inst.gpu_type || "GPU").toUpperCase()}`;
|
|
22
22
|
const vols = inst.volumes.map((v) => `${v.name} → ${v.mount}`).join(", ") || "—";
|
|
23
23
|
const age = timeSince(inst.created_at);
|
|
24
24
|
console.log(` ${bold(inst.name)} ${green("● running")} ${dim(age)}`);
|
package/dist/commands/sync.js
CHANGED
|
@@ -34,6 +34,15 @@ export async function sync() {
|
|
|
34
34
|
patterns.push(p.endsWith("/") ? `${p}**` : `**/${p}/**`);
|
|
35
35
|
}
|
|
36
36
|
}
|
|
37
|
+
// storage: true → skip "storage/" folder
|
|
38
|
+
if (config.storage === true) {
|
|
39
|
+
patterns.push("storage/**");
|
|
40
|
+
}
|
|
41
|
+
else if (Array.isArray(config.storage)) {
|
|
42
|
+
for (const p of config.storage) {
|
|
43
|
+
patterns.push(p.endsWith("/") ? `${p}**` : `**/${p}/**`);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
37
46
|
if (config.workspace?.storage) {
|
|
38
47
|
for (const p of config.workspace.storage) {
|
|
39
48
|
patterns.push(p.endsWith("/") ? `${p}**` : `**/${p}/**`);
|
package/dist/lib/push.js
CHANGED
|
@@ -10,6 +10,16 @@ export async function pushWorkspace(client, instanceId, config) {
|
|
|
10
10
|
patterns.push(p.endsWith("/") ? `${p}**` : `**/${p}/**`);
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
|
+
// storage: true → exclude "storage/" folder; storage: string[] → exclude each
|
|
14
|
+
if (config.storage === true) {
|
|
15
|
+
patterns.push("storage", "storage/**");
|
|
16
|
+
}
|
|
17
|
+
else if (Array.isArray(config.storage)) {
|
|
18
|
+
for (const p of config.storage) {
|
|
19
|
+
const name = p.replace(/\/$/, "");
|
|
20
|
+
patterns.push(`${name}`, `${name}/**`);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
13
23
|
if (config.workspace?.storage) {
|
|
14
24
|
for (const p of config.workspace.storage) {
|
|
15
25
|
const name = p.replace(/\/$/, "");
|
package/dist/lib/watcher.js
CHANGED
|
@@ -29,7 +29,16 @@ function buildIgnorePatterns(config) {
|
|
|
29
29
|
patterns.push(p.endsWith("/") ? `${p}**` : `**/${p}/**`);
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
|
-
// storage:
|
|
32
|
+
// storage: true → exclude "storage/" folder; array → exclude each path
|
|
33
|
+
if (config.storage === true) {
|
|
34
|
+
patterns.push("storage", "storage/**");
|
|
35
|
+
}
|
|
36
|
+
else if (Array.isArray(config.storage)) {
|
|
37
|
+
for (const p of config.storage) {
|
|
38
|
+
const name = p.replace(/\/$/, "");
|
|
39
|
+
patterns.push(name, `${name}/**`);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
33
42
|
if (config.workspace?.storage) {
|
|
34
43
|
for (const p of config.workspace.storage) {
|
|
35
44
|
const name = p.replace(/\/$/, "");
|
package/dist/types.d.ts
CHANGED