The Inline PowerShell VSTS task enables you to execute PowerShell from a textbox within your build or release pipeline. You can run a PowerShell script on you agent or on Azure. The task can be installed from the Marketplace.
How to use the task
First add the task to you build or release pipeline. Select the +Add tasks -> Utility -> Run Inline PowerShell:
Next you can enter the PowerShell script into the textbox:
Run your build or release to see the ‘Hello world’ in the logs.
Next you will be able to add argument to pass custom build variables. You need to pass them as arguments if they are marked as secret.
This will give you the following output:
Variables marked a secret will be shown as ********. This to prevent them to be reviled to everybody with access to the logs.