swiftroutercli 4.0.0 → 4.0.2

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 CHANGED
@@ -19,16 +19,23 @@ async function ensureConfig() {
19
19
  if (existingConfig && existingConfig.apiKey && existingConfig.baseUrl) {
20
20
  return existingConfig;
21
21
  }
22
+ let logoRendered = false;
22
23
  try {
23
24
  const logoPath = path.join(__dirname, "..", "assets", "logo.png");
24
25
  if (fs.existsSync(logoPath)) {
25
- console.log(await terminalImage.file(logoPath, { height: "25%" }));
26
+ const smallLogo = await terminalImage.file(logoPath, { height: 1, preserveAspectRatio: true });
27
+ // Print logo inline with welcome text
28
+ process.stdout.write(smallLogo.trimEnd() + " ");
29
+ console.log(chalk.cyan.bold("Welcome to SwiftRouterCLI!"));
30
+ logoRendered = true;
26
31
  }
27
32
  }
28
33
  catch (e) {
29
34
  // Ignore if logo cannot be rendered
30
35
  }
31
- console.log(chalk.cyan.bold("\n🌊 Welcome to SwiftRouterCLI!"));
36
+ if (!logoRendered) {
37
+ console.log(chalk.cyan.bold("\n🌊 Welcome to SwiftRouterCLI!"));
38
+ }
32
39
  console.log(chalk.gray("It looks like this is your first time. Let's get you set up.\n"));
33
40
  const rl = readline.createInterface({
34
41
  input: process.stdin,
@@ -48,7 +55,7 @@ async function ensureConfig() {
48
55
  program
49
56
  .name("swiftroutercli")
50
57
  .description("CLI for SwiftRouter AI Gateway")
51
- .version("4.0.0");
58
+ .version("4.0.2");
52
59
  program
53
60
  .command("config")
54
61
  .description("Manually configure the CLI with your SwiftRouter API Key and Base URL")
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "swiftroutercli",
3
- "version": "4.0.0",
3
+ "version": "4.0.2",
4
4
  "description": "The official SwiftRouter Command Line Interface using React Ink Components",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
package/src/index.ts CHANGED
@@ -23,16 +23,23 @@ async function ensureConfig(): Promise<Config> {
23
23
  return existingConfig;
24
24
  }
25
25
 
26
+ let logoRendered = false;
26
27
  try {
27
28
  const logoPath = path.join(__dirname, "..", "assets", "logo.png");
28
29
  if (fs.existsSync(logoPath)) {
29
- console.log(await terminalImage.file(logoPath, { height: "25%" }));
30
+ const smallLogo = await terminalImage.file(logoPath, { height: 1, preserveAspectRatio: true });
31
+ // Print logo inline with welcome text
32
+ process.stdout.write(smallLogo.trimEnd() + " ");
33
+ console.log(chalk.cyan.bold("Welcome to SwiftRouterCLI!"));
34
+ logoRendered = true;
30
35
  }
31
36
  } catch (e) {
32
37
  // Ignore if logo cannot be rendered
33
38
  }
34
39
 
35
- console.log(chalk.cyan.bold("\n🌊 Welcome to SwiftRouterCLI!"));
40
+ if (!logoRendered) {
41
+ console.log(chalk.cyan.bold("\n🌊 Welcome to SwiftRouterCLI!"));
42
+ }
36
43
  console.log(chalk.gray("It looks like this is your first time. Let's get you set up.\n"));
37
44
 
38
45
  const rl = readline.createInterface({
@@ -61,7 +68,7 @@ async function ensureConfig(): Promise<Config> {
61
68
  program
62
69
  .name("swiftroutercli")
63
70
  .description("CLI for SwiftRouter AI Gateway")
64
- .version("4.0.0");
71
+ .version("4.0.2");
65
72
 
66
73
  program
67
74
  .command("config")