One of my big tasks is writing software packaging scripts. I find them quite easy in batch files and vbs but have not been successful in powershell. Specifically I'd like to:
- run an exe
- with args
- with return code
- waiting for completion.
- do so in version 2.0 as desktops won't generally have 3.0 installed.
- However including
echoargs.exe
or the like along with the files would be acceptable.
I've found many postings on how to do each separate item but haven't found the right combination to provide all actions at once. Here's an example script.
msiexec.exe /qn /i somefile.msi /l*v somelog.log
Has anyone figured this out?