How to shut down computer when workflow finishes

Imagine it’s a late night, and you’re executing a long-running workflow on a personal laptop. You want to go to bed and don’t want to wait until the workflow finishes. How to make the workflow shut down the computer when it finishes?

A Windows installation comes with the “shutdown.exe” application that does exactly that - shuts down the computer. Just add the “Run program” action at the end of your workflow and configure it as in the screenshot below. Notice the command line arguments /s /t 0.