create-jilatax 0.1.8 → 0.1.9

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/bin.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  //#region src/bin.ts
3
- require("./cli-Dd1dGtrw.cjs").runCreateCli().then((exitCode) => {
3
+ require("./cli-CSUSszJB.cjs").runCreateCli().then((exitCode) => {
4
4
  process.exitCode = exitCode;
5
5
  });
6
6
  //#endregion
package/dist/bin.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { n as runCreateCli } from "./cli-BPjdtzvk.js";
2
+ import { n as runCreateCli } from "./cli-CmKnpwjR.js";
3
3
  //#region src/bin.ts
4
4
  runCreateCli().then((exitCode) => {
5
5
  process.exitCode = exitCode;
@@ -503,52 +503,23 @@ function startInstallProgress() {
503
503
  };
504
504
  }
505
505
  function printResult(result, log, interactive) {
506
- const lines = [
507
- "🛠️ build:",
506
+ const message = [
507
+ "🛠️ build:",
508
508
  ...result.installed ? [] : [" bun install"],
509
509
  " bun run dev",
510
510
  "",
511
511
  "🤖 Android:",
512
512
  " bun run run:android",
513
513
  " bun run create:aab"
514
- ];
515
- const message = lines.join("\n");
514
+ ].join("\n");
516
515
  const farewell = `cd ${formatProjectDirectory(result.projectDirectory)}, Good luck! 🎉`;
517
516
  if (interactive) {
518
- printResultPanel(lines);
517
+ _clack_prompts.note(message, "Result");
519
518
  node_process.stdout.write(`\n${farewell}\n`);
520
519
  return;
521
520
  }
522
521
  log(`${message}\n\n${farewell}`);
523
522
  }
524
- function printResultPanel(lines) {
525
- const terminalWidth = node_process.stdout.columns || 80;
526
- const panelWidth = Math.max(24, terminalWidth - 2);
527
- const contentWidth = panelWidth - 4;
528
- const titlePrefix = "╭─ Lynx / Jilatax ";
529
- const titleRuleWidth = Math.max(0, panelWidth - displayWidth(titlePrefix) - 1);
530
- const top = `${titlePrefix}${"─".repeat(titleRuleWidth)}╮`;
531
- const content = [
532
- "",
533
- ...lines,
534
- ""
535
- ].map((line) => {
536
- const padding = Math.max(0, contentWidth - displayWidth(line));
537
- return `│ ${line}${" ".repeat(padding)} │`;
538
- });
539
- const bottom = `╰${"─".repeat(panelWidth - 2)}╯`;
540
- node_process.stdout.write(`${[
541
- top,
542
- ...content,
543
- bottom
544
- ].join("\n")}\n`);
545
- }
546
- function displayWidth(value) {
547
- return [...value].reduce((width, character) => {
548
- if (/^[\uFE0E\uFE0F\u200D]$/u.test(character)) return width;
549
- return width + (/\p{Extended_Pictographic}/u.test(character) ? 2 : 1);
550
- }, 0);
551
- }
552
523
  function formatProjectDirectory(projectDirectory) {
553
524
  const relativeDirectory = node_path.default.relative(process.cwd(), projectDirectory);
554
525
  const cwdPath = relativeDirectory.length === 0 ? "." : relativeDirectory.startsWith("..") || node_path.default.isAbsolute(relativeDirectory) ? relativeDirectory : `.${node_path.default.sep}${relativeDirectory}`;
@@ -479,52 +479,23 @@ function startInstallProgress() {
479
479
  };
480
480
  }
481
481
  function printResult(result, log, interactive) {
482
- const lines = [
483
- "🛠️ build:",
482
+ const message = [
483
+ "🛠️ build:",
484
484
  ...result.installed ? [] : [" bun install"],
485
485
  " bun run dev",
486
486
  "",
487
487
  "🤖 Android:",
488
488
  " bun run run:android",
489
489
  " bun run create:aab"
490
- ];
491
- const message = lines.join("\n");
490
+ ].join("\n");
492
491
  const farewell = `cd ${formatProjectDirectory(result.projectDirectory)}, Good luck! 🎉`;
493
492
  if (interactive) {
494
- printResultPanel(lines);
493
+ prompts.note(message, "Result");
495
494
  stdout.write(`\n${farewell}\n`);
496
495
  return;
497
496
  }
498
497
  log(`${message}\n\n${farewell}`);
499
498
  }
500
- function printResultPanel(lines) {
501
- const terminalWidth = stdout.columns || 80;
502
- const panelWidth = Math.max(24, terminalWidth - 2);
503
- const contentWidth = panelWidth - 4;
504
- const titlePrefix = "╭─ Lynx / Jilatax ";
505
- const titleRuleWidth = Math.max(0, panelWidth - displayWidth(titlePrefix) - 1);
506
- const top = `${titlePrefix}${"─".repeat(titleRuleWidth)}╮`;
507
- const content = [
508
- "",
509
- ...lines,
510
- ""
511
- ].map((line) => {
512
- const padding = Math.max(0, contentWidth - displayWidth(line));
513
- return `│ ${line}${" ".repeat(padding)} │`;
514
- });
515
- const bottom = `╰${"─".repeat(panelWidth - 2)}╯`;
516
- stdout.write(`${[
517
- top,
518
- ...content,
519
- bottom
520
- ].join("\n")}\n`);
521
- }
522
- function displayWidth(value) {
523
- return [...value].reduce((width, character) => {
524
- if (/^[\uFE0E\uFE0F\u200D]$/u.test(character)) return width;
525
- return width + (/\p{Extended_Pictographic}/u.test(character) ? 2 : 1);
526
- }, 0);
527
- }
528
499
  function formatProjectDirectory(projectDirectory) {
529
500
  const relativeDirectory = path.relative(process.cwd(), projectDirectory);
530
501
  const cwdPath = relativeDirectory.length === 0 ? "." : relativeDirectory.startsWith("..") || path.isAbsolute(relativeDirectory) ? relativeDirectory : `.${path.sep}${relativeDirectory}`;
package/dist/index.cjs CHANGED
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_cli = require("./cli-Dd1dGtrw.cjs");
2
+ const require_cli = require("./cli-CSUSszJB.cjs");
3
3
  exports.createHelpText = require_cli.createHelpText;
4
4
  exports.createProject = require_cli.createProject;
5
5
  exports.defaultPackageId = require_cli.defaultPackageId;
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import { a as normalizeDisplayName, i as defaultPackageId, n as runCreateCli, o as normalizeProjectName, r as createProject, s as validatePackageId, t as createHelpText } from "./cli-BPjdtzvk.js";
1
+ import { a as normalizeDisplayName, i as defaultPackageId, n as runCreateCli, o as normalizeProjectName, r as createProject, s as validatePackageId, t as createHelpText } from "./cli-CmKnpwjR.js";
2
2
  export { createHelpText, createProject, defaultPackageId, normalizeDisplayName, normalizeProjectName, runCreateCli, validatePackageId };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-jilatax",
3
- "version": "0.1.8",
3
+ "version": "0.1.9",
4
4
  "packageManager": "bun@1.3.4",
5
5
  "description": "Create an Android-first Jilatax application for Lynx and Rspeedy.",
6
6
  "type": "module",