install-rynude 1.0.5 → 1.0.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.
Files changed (2) hide show
  1. package/index.js +22 -5
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -11,16 +11,33 @@ const REPO_URL = 'https://github.com/flustratech-dev/rynude_ai.git';
11
11
  const INSTALL_DIR = path.join(os.homedir(), '.rynude_ai');
12
12
 
13
13
  async function checkRequirements() {
14
- const reqs = ['git', 'php', 'composer', 'npm'];
14
+ const reqs = [
15
+ { cmd: 'php', name: 'PHP', download: 'https://windows.php.net/download/' },
16
+ { cmd: 'composer', name: 'Composer', download: 'https://getcomposer.org/Composer-Setup.exe' },
17
+ { cmd: 'git', name: 'Git', download: 'https://git-scm.com/downloads' },
18
+ { cmd: 'npm', name: 'Node.js/NPM', download: 'https://nodejs.org/' }
19
+ ];
20
+
21
+ let hasMissing = false;
22
+ let statusMessage = '\n';
23
+
15
24
  for (const req of reqs) {
16
25
  try {
17
- execSync(`${req} --version`, { stdio: 'ignore' });
26
+ execSync(`${req.cmd} --version`, { stdio: 'ignore' });
27
+ statusMessage += chalk.green(`[✓] ${req.name} (Ditemukan)\n`);
18
28
  } catch (e) {
19
- console.error(chalk.red(`\n❌ Error: Program '${req}' tidak ditemukan di sistem Anda.`));
20
- console.error(chalk.yellow(`Silakan install ${req} terlebih dahulu sebelum menginstal Rynude AI.\n`));
21
- process.exit(1);
29
+ hasMissing = true;
30
+ statusMessage += chalk.red(`[x] ${req.name} (Tidak Ditemukan) -> Download: ${req.download}\n`);
22
31
  }
23
32
  }
33
+
34
+ if (hasMissing) {
35
+ console.error(chalk.red.bold('\n❌ Instalasi Dihentikan: Komponen Hilang!'));
36
+ console.error(chalk.white('Rynude AI membutuhkan beberapa alat tambahan di komputer Anda:'));
37
+ console.error(statusMessage);
38
+ console.error(chalk.yellow.bold('Silakan install aplikasi yang disilang merah, lalu BUKA TERMINAL/CMD BARU dan ketik ulang "npx install-rynude".\n'));
39
+ process.exit(1);
40
+ }
24
41
  }
25
42
 
26
43
  async function run() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "install-rynude",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "Auto-installer for Rynude AI",
5
5
  "main": "index.js",
6
6
  "type": "module",