From 8a4f7163bb8ac6e29ccc7394138c1d15d4d4d531 Mon Sep 17 00:00:00 2001 From: Nick Hammond Date: Mon, 20 May 2024 11:15:14 -0700 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Donal McBreen --- lib/kamal/cli/server.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/kamal/cli/server.rb b/lib/kamal/cli/server.rb index 58eed4af..c89bee61 100644 --- a/lib/kamal/cli/server.rb +++ b/lib/kamal/cli/server.rb @@ -1,12 +1,12 @@ class Kamal::Cli::Server < Kamal::Cli::Base - desc "exec", "Run a custom command on the server(use --help to show options)" + desc "exec", "Run a custom command on the server (use --help to show options)" option :interactive, type: :boolean, aliases: "-i", default: false, desc: "Run the command interactively(use for console/bash)" def exec(cmd) hosts = KAMAL.hosts | KAMAL.accessory_hosts case when options[:interactive] - host = hosts.first + host = KAMAL.primary_host say "Running '#{cmd}' on #{host} interactively...", :magenta