浏览代码

fix(cli): switch clap help texts to English

All /// doc comments and #[arg(help)] attributes were a mix of Russian
and English. Unified to English for consistency — CLI i18n (via builder
API or clap-i18n-richformatter) can be revisited later if needed.
Alexander Korolev 4 月之前
父节点
当前提交
746049fc18
共有 1 个文件被更改,包括 19 次插入 和 19 次删除
  1. 19 19
      src/cli.rs

+ 19 - 19
src/cli.rs

@@ -1,12 +1,12 @@
 use clap::{Parser, Subcommand};
 
 #[derive(Parser)]
-#[command(author, version, about = "DGX Spark Launcher для vLLM и SGLang")]
+#[command(author, version, about = "DGX Spark Launcher for vLLM and SGLang")]
 pub struct Cli {
     #[arg(long, short, default_value = "config.toml")]
     pub config: String,
 
-    #[arg(long, short, help = "Показать команды без выполнения")]
+    #[arg(long, short, help = "Show commands without executing")]
     pub dry_run: bool,
 
     #[command(subcommand)]
@@ -15,7 +15,7 @@ pub struct Cli {
 
 #[derive(Subcommand)]
 pub enum Commands {
-    /// Запустить кластер
+    /// Launch a cluster
     Serve {
         #[arg(long, required = true)]
         recipe: String,
@@ -40,7 +40,7 @@ pub enum Commands {
         follow: bool,
     },
 
-    /// Показать логи контейнеров
+    /// Show container logs
     Logs {
         #[arg(long, required = true)]
         recipe: String,
@@ -52,7 +52,7 @@ pub enum Commands {
         cluster: String,
     },
 
-    /// Остановить кластер
+    /// Stop a cluster
     Stop {
         #[arg(long, required = true)]
         recipe: String,
@@ -65,38 +65,38 @@ pub enum Commands {
         cluster: String,
     },
 
-    /// Проверить здоровье кластера
+    /// Check cluster health
     Health {
         #[arg(
             long,
-            help = "Имя кластера (например, 4nodes-switch). Если не указано - проверяет все."
+            help = "Cluster name (e.g. 4nodes-switch). If omitted — checks all."
         )]
         cluster: Option<String>,
         #[arg(
             long,
-            help = "Показать хост-ключи узлов (для добавления в config.toml)"
+            help = "Show node host keys (for adding to config.toml)"
         )]
         fingerprint: bool,
     },
 
-    /// Проверить и исправить рецепт (doctor mode)
+    /// Check and repair a recipe (doctor mode)
     Doctor {
-        #[arg(long, required = true, help = "Имя рецепта для проверки")]
+        #[arg(long, required = true, help = "Recipe name to check")]
         recipe: String,
         #[arg(
             long,
             default_value = "auto",
-            help = "Кластер (если не auto — использует recipe.cluster)"
+            help = "Cluster (if not auto — uses recipe.cluster)"
         )]
         cluster: String,
         #[arg(
             long,
-            help = "Автоматически исправить проблемы (создать Dockerfile + собрать образ)"
+            help = "Auto-fix issues (create Dockerfile + build image)"
         )]
         repair: bool,
     },
 
-    /// Управление tmux-сессиями (альтернатива Docker)
+    /// Manage tmux sessions (Docker alternative)
     #[command(subcommand)]
     Tmux(TmuxCommands),
 
@@ -104,7 +104,7 @@ pub enum Commands {
     InitHostKeys {
         #[arg(
             long,
-            help = "Имя кластера (например, 4nodes-switch). Если не указано — все."
+            help = "Cluster name (e.g. 4nodes-switch). If omitted — all."
         )]
         cluster: Option<String>,
     },
@@ -173,7 +173,7 @@ pub enum PowerAction {
 
 #[derive(Subcommand)]
 pub enum TmuxCommands {
-    /// Запустить кластер через tmux
+    /// Launch cluster via tmux
     Serve {
         #[arg(long, required = true)]
         recipe: String,
@@ -183,21 +183,21 @@ pub enum TmuxCommands {
         #[arg(long, default_value = "false")]
         skip_before_serve: bool,
     },
-    /// Остановить tmux-сессии
+    /// Stop tmux sessions
     Stop {
         #[arg(long, required = true)]
         recipe: String,
         #[arg(long, default_value = "auto")]
         cluster: String,
     },
-    /// Статус tmux-сессий (подробный)
+    /// Detailed tmux session status
     Status {
         #[arg(long, required = true)]
         recipe: String,
         #[arg(long, default_value = "auto")]
         cluster: String,
     },
-    /// Показать логи tmux-сессий
+    /// Show tmux session logs
     Logs {
         #[arg(long, required = true)]
         recipe: String,
@@ -206,7 +206,7 @@ pub enum TmuxCommands {
         #[arg(long, default_value = "auto")]
         cluster: String,
     },
-    /// Подключиться к tmux-сессии головного узла
+    /// Attach to head node tmux session
     Attach {
         #[arg(long, required = true)]
         recipe: String,