vipcare 0.3.11 → 0.3.12

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.
Files changed (2) hide show
  1. package/bin/vip.js +42 -0
  2. package/package.json +1 -1
package/bin/vip.js CHANGED
@@ -830,6 +830,48 @@ program.command('init')
830
830
  const { CONFIG_FILE: cfgPath } = await import('../lib/config.js');
831
831
  console.log(c.green(`\nConfig saved to ${cfgPath}`));
832
832
 
833
+ // --- Check & install dependencies ---
834
+ console.log(c.bold(c.cyan('\nChecking dependencies...\n')));
835
+
836
+ const deps = [
837
+ { name: 'bird', label: 'Bird CLI (Twitter data)', install: 'npm install -g @nickytonline/bird', check: () => checkTool('bird') },
838
+ { name: 'ddgs', label: 'DDGS (web search)', install: 'pip install ddgs', check: () => checkTool('ddgs') || fs.existsSync(path.join(os.homedir(), 'Library', 'Python', '3.9', 'bin', 'ddgs')) },
839
+ { name: 'claude', label: 'Claude Code CLI (AI synthesis)', install: 'npm install -g @anthropic-ai/claude-code', check: () => checkTool('claude') },
840
+ { name: 'yt-dlp', label: 'yt-dlp (YouTube download)', install: 'pip install yt-dlp', check: () => checkTool('yt-dlp') },
841
+ { name: 'whisper', label: 'Whisper (YouTube transcription)', install: 'pip install openai-whisper', check: () => checkTool('whisper') },
842
+ ];
843
+
844
+ const missing = [];
845
+ for (const dep of deps) {
846
+ const ok = dep.check();
847
+ console.log(` ${ok ? c.green('✓') : c.red('✗')} ${dep.label}`);
848
+ if (!ok) missing.push(dep);
849
+ }
850
+
851
+ if (missing.length > 0) {
852
+ console.log(`\n${c.yellow(`${missing.length} optional dependency(ies) not found.`)}`);
853
+ const installAnswer = await rl.question(' Install missing dependencies? (Y/n) > ');
854
+ if (!installAnswer.trim() || installAnswer.trim().toLowerCase().startsWith('y')) {
855
+ for (const dep of missing) {
856
+ console.log(c.dim(` Installing ${dep.name}...`));
857
+ try {
858
+ const [cmd, ...args] = dep.install.split(' ');
859
+ execFileSync(cmd, args, { stdio: 'inherit', timeout: 120000 });
860
+ console.log(c.green(` ✓ ${dep.name} installed`));
861
+ } catch {
862
+ console.log(c.yellow(` ✗ Failed to install ${dep.name}. Install manually: ${dep.install}`));
863
+ }
864
+ }
865
+ } else {
866
+ console.log(c.dim(' Skipped. Install later with:'));
867
+ for (const dep of missing) {
868
+ console.log(c.dim(` ${dep.install}`));
869
+ }
870
+ }
871
+ } else {
872
+ console.log(c.green('\n All dependencies available!'));
873
+ }
874
+
833
875
  // Install Claude Code skill by default
834
876
  const skillSrc = new URL('../skill/vip.md', import.meta.url);
835
877
  const skillDest = path.join(os.homedir(), '.claude', 'commands', 'vip.md');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vipcare",
3
- "version": "0.3.11",
3
+ "version": "0.3.12",
4
4
  "description": "Auto-build VIP person profiles from Twitter/LinkedIn public data",
5
5
  "type": "module",
6
6
  "bin": {