Skip to content
This repository was archived by the owner on Feb 12, 2025. It is now read-only.

Powershell -file doesn't handle arguments that are string[] #260

Closed
wants to merge 1 commit into from
Closed

Powershell -file doesn't handle arguments that are string[] #260

wants to merge 1 commit into from

Conversation

mintsoft
Copy link
Contributor

However executing the string like -Command does, basically if you do:
powershell -file MyScript.ps1 -computers server1,server2,server3 then the script recieves one argument called computers with the value server1,server2,server3

however using powershell -Command MyScript.ps1 -computers server1,server2,server3 then the script receives one argument called computers with the value of an array containing server1 server2 and server3

However I want this backwards compatible just incase unlike #255

…le; -Command does

however I want this backwards compatible just incase. Fixes #255
@mintsoft mintsoft closed this by deleting the head repository Apr 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant