@lythos/skill-deck 0.1.1 → 0.1.2
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/package.json +1 -1
- package/src/link.ts +11 -9
package/package.json
CHANGED
package/src/link.ts
CHANGED
|
@@ -23,14 +23,8 @@ import {
|
|
|
23
23
|
// ── 路径工具 ────────────────────────────────────────────────
|
|
24
24
|
|
|
25
25
|
function findDeckToml(from: string): string | null {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
const p = join(dir, "skill-deck.toml");
|
|
29
|
-
if (existsSync(p)) return p;
|
|
30
|
-
const parent = dirname(dir);
|
|
31
|
-
if (parent === dir) break;
|
|
32
|
-
dir = parent;
|
|
33
|
-
}
|
|
26
|
+
const p = join(from, "skill-deck.toml");
|
|
27
|
+
if (existsSync(p)) return p;
|
|
34
28
|
return null;
|
|
35
29
|
}
|
|
36
30
|
|
|
@@ -127,7 +121,15 @@ const DECK_PATH = cliDeck
|
|
|
127
121
|
: findDeckToml(process.cwd()) || resolve("skill-deck.toml");
|
|
128
122
|
|
|
129
123
|
if (!existsSync(DECK_PATH)) {
|
|
130
|
-
console.error(`❌ ${
|
|
124
|
+
console.error(`❌ skill-deck.toml not found in ${process.cwd()}`);
|
|
125
|
+
console.error(`\nCreate one:`);
|
|
126
|
+
console.error(` cat > skill-deck.toml <<'EOF'`);
|
|
127
|
+
console.error(` [deck]`);
|
|
128
|
+
console.error(` max_cards = 10`);
|
|
129
|
+
console.error(` \n [tool]`);
|
|
130
|
+
console.error(` skills = ["lythoskill-deck"]`);
|
|
131
|
+
console.error(` EOF`);
|
|
132
|
+
console.error(`\nOr specify a path: bunx @lythos/skill-deck link --deck /path/to/deck.toml`);
|
|
131
133
|
process.exit(1);
|
|
132
134
|
}
|
|
133
135
|
|