@nimbuslab/cli 0.16.5 → 0.16.7
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 +36 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -150,7 +150,7 @@ var require_src = __commonJS((exports, module) => {
|
|
|
150
150
|
var require_package = __commonJS((exports, module) => {
|
|
151
151
|
module.exports = {
|
|
152
152
|
name: "@nimbuslab/cli",
|
|
153
|
-
version: "0.16.
|
|
153
|
+
version: "0.16.6",
|
|
154
154
|
description: "CLI para criar projetos nimbuslab",
|
|
155
155
|
type: "module",
|
|
156
156
|
bin: {
|
|
@@ -2590,7 +2590,11 @@ async function update(args) {
|
|
|
2590
2590
|
} else {
|
|
2591
2591
|
M2.success(`${PACKAGE_NAME} atualizado: ${currentVersion} -> ${newVersion}`);
|
|
2592
2592
|
}
|
|
2593
|
-
|
|
2593
|
+
const isWindows = process.platform === "win32";
|
|
2594
|
+
if (isWindows) {
|
|
2595
|
+
console.log();
|
|
2596
|
+
console.log(import_picocolors6.default.yellow(" Reinicie o terminal para aplicar a atualizacao."));
|
|
2597
|
+
} else if (isUsingFnm()) {
|
|
2594
2598
|
console.log();
|
|
2595
2599
|
console.log(import_picocolors6.default.yellow(" fnm detectado - execute para aplicar:"));
|
|
2596
2600
|
console.log(import_picocolors6.default.cyan(" hash -r"));
|
|
@@ -2623,6 +2627,8 @@ var HOME = homedir();
|
|
|
2623
2627
|
var LOLA_DIR = join3(HOME, ".lola");
|
|
2624
2628
|
var LOLA_REPO = "git@github.com:nimbuslab/lola.git";
|
|
2625
2629
|
var USER_MEMORY = join3(HOME, ".claude", "USER_MEMORY.md");
|
|
2630
|
+
var CLAUDE_COMMANDS_DIR = join3(HOME, ".claude", "commands");
|
|
2631
|
+
var LOLA_COMMANDS_DIR = join3(LOLA_DIR, "commands");
|
|
2626
2632
|
var LOLA_MEMORY_URL = "https://lola.nimbuslab.com.br/sse";
|
|
2627
2633
|
var LOLA_MEMORY_NAME = "lola-memory";
|
|
2628
2634
|
var GEMINI_DIR = join3(HOME, ".gemini");
|
|
@@ -2679,6 +2685,33 @@ async function installLolaMemoryMCP() {
|
|
|
2679
2685
|
console.log(import_picocolors7.default.dim(' learn "content" - Salvar conhecimento'));
|
|
2680
2686
|
console.log(import_picocolors7.default.dim(" memory_stats - Ver estatisticas"));
|
|
2681
2687
|
}
|
|
2688
|
+
async function installLolaCommands() {
|
|
2689
|
+
console.log();
|
|
2690
|
+
console.log(import_picocolors7.default.cyan(" Instalando comandos da Lola..."));
|
|
2691
|
+
if (!existsSync2(LOLA_COMMANDS_DIR)) {
|
|
2692
|
+
console.log(import_picocolors7.default.dim(" Pasta de comandos nao encontrada em ~/.lola/commands"));
|
|
2693
|
+
return;
|
|
2694
|
+
}
|
|
2695
|
+
if (!existsSync2(CLAUDE_COMMANDS_DIR)) {
|
|
2696
|
+
await Bun.$`mkdir -p ${CLAUDE_COMMANDS_DIR}`;
|
|
2697
|
+
}
|
|
2698
|
+
const glob = new Bun.Glob("*.md");
|
|
2699
|
+
const files = Array.from(glob.scanSync({ cwd: LOLA_COMMANDS_DIR }));
|
|
2700
|
+
if (files.length === 0) {
|
|
2701
|
+
console.log(import_picocolors7.default.dim(" Nenhum comando encontrado"));
|
|
2702
|
+
return;
|
|
2703
|
+
}
|
|
2704
|
+
let installed = 0;
|
|
2705
|
+
for (const file of files) {
|
|
2706
|
+
const src = join3(LOLA_COMMANDS_DIR, file);
|
|
2707
|
+
const dest = join3(CLAUDE_COMMANDS_DIR, file);
|
|
2708
|
+
const content = await Bun.file(src).text();
|
|
2709
|
+
await Bun.write(dest, content);
|
|
2710
|
+
installed++;
|
|
2711
|
+
}
|
|
2712
|
+
console.log(import_picocolors7.default.green(` ${installed} comandos instalados!`));
|
|
2713
|
+
console.log(import_picocolors7.default.dim(" Comandos: /inbox, /sent, /msg, /conversation"));
|
|
2714
|
+
}
|
|
2682
2715
|
async function installGeminiCLI() {
|
|
2683
2716
|
console.log();
|
|
2684
2717
|
console.log(import_picocolors7.default.cyan(" Instalando Gemini CLI..."));
|
|
@@ -3352,6 +3385,7 @@ fi
|
|
|
3352
3385
|
}
|
|
3353
3386
|
}
|
|
3354
3387
|
await installLolaMemoryMCP();
|
|
3388
|
+
await installLolaCommands();
|
|
3355
3389
|
const claudeDir = join3(HOME, ".claude");
|
|
3356
3390
|
if (!existsSync2(USER_MEMORY)) {
|
|
3357
3391
|
console.log();
|