Module: VagrantPlugins::GuestMSYS2::Util::CapHelpers

Defined in:
lib/vagrant-guest-msys2/util/cap_helpers.rb

Class Method Summary collapse

Class Method Details

.wrap_powershell(script) ⇒ Object



5
6
7
8
9
10
11
12
# File 'lib/vagrant-guest-msys2/util/cap_helpers.rb', line 5

def self.wrap_powershell(script)
  wrapped = <<-EOH.gsub(/^ {12}/, '')
    cat << 'EOF' | powershell -InputFormat none -Command - 
    #{script}
    EOF
  EOH
  wrapped
end