Run commands across WSL distros
You can pipe outputs from various distros and Windows as well to run commmands across WSL distros. For example, this command will take output from PowerShell, filter it in Debian, and then output it using cowsay in Ubuntu.
Write-Output "Hello from Windows`nHello from Linux!" | wsl -d Debian grep -i linux | wsl -d Ubuntu cowsay
- More from this author:
- craigaloewen
- craigloewen-msft
- Website