Powershell: Expect like capability with PowerShell

Created on 29 Sep 2017  路  3Comments  路  Source: PowerShell/PowerShell

Hi there,

I'm just trying to find a tech for macOS which can be used to automate CLI commands, Like Expect https://en.wikipedia.org/wiki/Expect

So can i use PowerShell for that?

Please advise.

Issue-Enhancement Issue-Question Resolution-Answered

Most helpful comment

There is a PowerShell module that is supposed to mimic Expect in PowerShell. https://www.powershellgallery.com/packages/Await/0.8

All 3 comments

I don't think you could do this easily in PowerShell today, but there are ways with PowerShell to redirect stdin/stdout of a console app. Perhaps this is something we could have better support for once we have DSL available.

However, you should be able to use Expect within PowerShell today.

There is a PowerShell module that is supposed to mimic Expect in PowerShell. https://www.powershellgallery.com/packages/Await/0.8

@rkeithhill awesome!

Was this page helpful?
0 / 5 - 0 ratings