packer-community / winrmcp

Copy files to a remote host using WinRM
MIT License
59 stars 31 forks source link

Allow passing in a winrm client #37

Open kke opened 4 years ago

kke commented 4 years ago

I think plenty of people are using this together with the masterzen/winrm package, which is a dependency of this package too, so there's already code for setting up the winrm client.

The winrmcp package could accept an existing winrm.Client instead of having to set up a new one through winrmcp.New()

Because Winrmcp{}'s config and client are unexported, you can't do something like winrmcp.Winrmcp{client: existingclient, config: winrmcp.Config{....}}.