2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 1 year has passed since last update.

Windows Terminal上で処理実行中にコンソールをクリック

Last updated at Posted at 2023-07-27

コマンドプロンプト、PowerShellのコンソールを問わず。

Windowsのコンソール上で処理を実行中に、コンソールをクリックするとプロンプトが簡易編集モードとなり、実行している処理が停止してしまう。

これを知らずに、途中で処理を停止してしまう失敗話はWindowsではよく聞く話かと思います。

コマンドプロンプトやPowerShellで処理が停止するのを確認する方法としては ping -t localhost といった実行を繰り返すコマンドを実行して、コンソール上をクリックすると確認できます。(クリックすると簡易編集モードになり処理が停止)

image.png

いままでWindowsのコンソールはそういう物だといった理解をしていたのですが。

最近、Windows Terminal上で起動したcmd.exePowerShellはクリックや範囲選択をしても処理が停止しないことに気が付きました。

image.png

気づいた際のWindows Terminalバージョンは下記の通りとなっており。

  • Windows ターミナル (プレビュー)
  • バージョン: 1.18.1462.0

ここらへんの動作について何か記載されていないかと、microsoft/terminal を検索した所、画面出力周りで下記が引っかかりました。

terminal output freezes on click #408

Feature Request: Pause output or scrolling on click (and make it a setting) #980

Feature Request: Preserve scroll position while not "at bottom" #3863

Add a spec for output snapping #2529

Implement preventing auto-scroll on new output #6062

doc/specs/#980 - SnapOnOutput.md

なんとなくWindows Terminalでは初期からコンソール処理中に画面をクリックしても現在のように処理が停止するといった事はなかったっぽい?

総評

Windows Terminalを使い始めてしばらくたちますが、いまさら気がつきました。

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?