Skip to content

Commit

Permalink
Merge branch 'CHEF-1929'
Browse files Browse the repository at this point in the history
  • Loading branch information
Seth Falcon committed May 25, 2011
2 parents 418f1aa + f8af352 commit 32cc997
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion chef/lib/chef/knife/ssh.rb
Expand Up @@ -241,6 +241,7 @@ def screen
window = 0
session.servers_for.each do |server|
tf.print("screen -t \"#{server.host}\" #{window} ssh ")
tf.print("-i #{config[:identity_file]} ") if config[:identity_file]
server.user ? tf.puts("#{server.user}@#{server.host}") : tf.puts(server.host)
window += 1
end
Expand All @@ -250,8 +251,9 @@ def screen

def tmux
ssh_dest = lambda do |server|
identity = "-i #{config[:identity_file]} " if config[:identity_file]
prefix = server.user ? "#{server.user}@" : ""
"'ssh #{prefix}#{server.host}'"
"'ssh #{identity}#{prefix}#{server.host}'"
end

new_window_cmds = lambda do
Expand Down

0 comments on commit 32cc997

Please sign in to comment.