问题
We regularly access the build machine through RDP and it there are lots of command line windows that open. Sometimes these windows hang like someone switched focus to them and press the Pause key. Tapping the keyboard moves the process along, but every once in a while this is missed and everyone waits on the process to finish while it is waiting for someone to press a key. Why does this happen? Is there a setting or version up/down-grade that can keep it from happening?
回答1:
When this happens, does the window title say "Select Command Prompt"? If so, hitting a key will unpause it, but the keystroke will also be sent to the paused program unless it's ESC or enter (or possibly others). You can turn this feature off by going into the Command Prompt properties/defaults and unchecking "QuickEdit Mode".
If that's not it, you'll have to post more information about your build process. What is your build system written in (make, scons, jam, msbuild, etc.)?
回答2:
One thing to watch out for in command line Windows; if you have QuickEdit Mode enabled (click on icon in title bar, Properties..., Options tab) you can highlight and copy with the mouse, bypassing the Edit menu. Stray mouse clicks in the window highlight the character underneath and the console will appear to "hang" until a key is pressed.
来源:https://stackoverflow.com/questions/591047/command-line-windows-hanging-in-rdp-windows