@fswap/mcp-vikunja 0.1.4 → 0.1.6
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/index.js +8 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -543,8 +543,13 @@ function abort() {
|
|
|
543
543
|
p.cancel("Setup aborted.");
|
|
544
544
|
process.exit(1);
|
|
545
545
|
}
|
|
546
|
+
/** Plain stdout, no box drawing, so the snippets can be selected and copied (or piped to a file). */
|
|
546
547
|
function printSnippets(missing) {
|
|
547
|
-
for (const s of clientSnippets(missing))
|
|
548
|
+
for (const s of clientSnippets(missing)) {
|
|
549
|
+
console.log(`\n# ${s.title}\n`);
|
|
550
|
+
console.log(s.body);
|
|
551
|
+
}
|
|
552
|
+
console.log();
|
|
548
553
|
}
|
|
549
554
|
async function runSetup(args = []) {
|
|
550
555
|
if (args.includes("--reset")) {
|
|
@@ -626,8 +631,9 @@ async function runSetup(args = []) {
|
|
|
626
631
|
if (!url) missing[ENV_URL] = "https://try.vikunja.io";
|
|
627
632
|
if (!token) missing[ENV_TOKEN] = "tk_...";
|
|
628
633
|
if (Object.keys(missing).length > 0) p.log.warn(`Still needed: ${Object.keys(missing).join(", ")}. Add them to the env block below, or run setup again.`);
|
|
629
|
-
printSnippets(missing);
|
|
630
634
|
p.outro(`Saved to ${file}`);
|
|
635
|
+
console.log("Add one of these to your MCP client (plain text, safe to copy). Re-print any time with: setup --print");
|
|
636
|
+
printSnippets(missing);
|
|
631
637
|
}
|
|
632
638
|
var init_setup = __esmMin((() => {
|
|
633
639
|
init_config();
|