lib/vagrant/action/builtin/ssh_run.rb in vagrant-unbundled-1.9.5.1 vs lib/vagrant/action/builtin/ssh_run.rb in vagrant-unbundled-1.9.7.1

- old
+ new

@@ -42,10 +42,12 @@ opts = env[:ssh_opts] || {} opts[:extra_args] ||= [] # Allow the user to specify a tty or non-tty manually, but if they # don't then we default to a TTY - if !opts[:extra_args].include?("-t") && !opts[:extra_args].include?("-T") + if !opts[:extra_args].include?("-t") && + !opts[:extra_args].include?("-T") && + env[:tty] opts[:extra_args] << "-t" end opts[:extra_args] << command opts[:subprocess] = true