3 ms·
WSL 1 (haven't tried 2 if they have some sort of magic for this, guess not) can actually run windows applications. So you can run "ipconfig.exe | cowsay" for i
by tjoff 6y ago
WSL 1 (haven't tried 2 if they have some sort of magic for this, guess not) can actually run windows applications.
So you can run "ipconfig.exe | cowsay" for instance.
I'm not in front of a windows machine now but you could do stuff like list windows processes with a windows command, filter it with linux command and take the result to kill a process. All in a short line.
And honestly, more integrated than that I'm not sure I want. I like isolation and knowing that my linux command won't touch windows processes etc.
But an utility that can list and kill both Linux and windows processes can be done in a short shell-script.
- 1996 6y agoThe same is possible in msys2, and actually very useful. For example, to find my IP, from my bash prompt on windows 10: /c/Windows/System32/ipconfig.exe | grep "^\s\s\sIPv" | sed -e 's/.*: //g'
- shawnz 6y agoWSL 2 actually also supports that integration. It works by transparently sending the stdio over the network to/from the host instead.