How do I use a pipe to redirect the output of one command to the input of another?

前端 未结 4 554
生来不讨喜
生来不讨喜 2020-12-03 02:26

I have a program which sends text to an LED sign.

prismcom.exe

To use the program to send \"Hello\":

prismcom.exe usb Hello

4条回答
  •  囚心锁ツ
    2020-12-03 03:11

    You can also run exactly same command at Cmd.exe command-line using PowerShell. I'd go with this approach for simplicity...

    C:\>PowerShell -Command "temperature | prismcom.exe usb"
    

    Please read up on Understanding the Windows PowerShell Pipeline

    You can also type in C:\>PowerShell at the command-line and it'll put you in PS C:\> mode instanctly, where you can directly start writing PS.

提交回复
热议问题