From aabc60cbb3fde46f1a12aefc5a41621b33352b64 Mon Sep 17 00:00:00 2001 From: h-east Date: Sun, 24 Nov 2024 01:57:04 +0900 Subject: [PATCH] Update terminal.{txt,jax} --- doc/terminal.jax | 15 ++++++++++++++- en/terminal.txt | 15 ++++++++++++++- 2 files changed, 28 insertions(+), 2 deletions(-) diff --git a/doc/terminal.jax b/doc/terminal.jax index b6b3f3f3d..6e7761383 100644 --- a/doc/terminal.jax +++ b/doc/terminal.jax @@ -1,4 +1,4 @@ -*terminal.txt* For Vim バージョン 9.1. Last change: 2024 Nov 19 +*terminal.txt* For Vim バージョン 9.1. Last change: 2024 Nov 23 VIMリファレンスマニュアル by Bram Moolenaar @@ -196,6 +196,13 @@ Normal ハイライトグループにより決定される。 [command] が NONE の場合ジョブは開始されず、端末の pty は gdb のようなコマンドによって利用できる。 + *terminal-nospecial* + Vim 自体は [command] 内の |cmdline-special| 文字のみを + 認識する。その他はすべてそのまま渡される。ワイルドカー + ド、環境変数、またはその他のシェル特殊文字を展開する必 + 要がある場合は、|term++shell| オプションを検討するこ + と。 + [command] がない場合、デフォルトの動作はシェルが終了し たときに端末を閉じる。この動作は ++noclose 引数で変更 できる。 @@ -240,10 +247,16 @@ Normal ハイライトグループにより決定される。 ウは使用されない。 ++norestore セッションファイルに端末ウィンドウを含 めない。 + + *term++shell* ++shell {command} を直接実行するのではなく、 `:!command` と同様にシェルを使用する。 *E279* {Vim: UnixとMS-Windowsでのみ動作する} + 結果のコマンドは次のようになる + 'shell' 'shellcmdflag' [command] + `:!command` に関連するその他のオプショ + ンは効果がない。 ++kill={how} 端末ウィンドウを閉じるときに {how} で ジョブを終了させる。値については |term_setkill()| を参照。 diff --git a/en/terminal.txt b/en/terminal.txt index 593dec77c..a0bfd6034 100644 --- a/en/terminal.txt +++ b/en/terminal.txt @@ -1,4 +1,4 @@ -*terminal.txt* For Vim version 9.1. Last change: 2024 Nov 19 +*terminal.txt* For Vim version 9.1. Last change: 2024 Nov 23 VIM REFERENCE MANUAL by Bram Moolenaar @@ -197,6 +197,13 @@ Command syntax ~ if [command] is NONE no job is started, the pty of the terminal can be used by a command like gdb. + *terminal-nospecial* + Vim itself only recognizes |cmdline-special| + characters inside [command]. Everything else will be + passed untouched. When needed to expand wildcards, + environment variables or other shell specials consider + |term++shell| option. + If [command] is missing the default behavior is to close the terminal when the shell exits. This can be changed with the ++noclose argument. @@ -241,10 +248,16 @@ Command syntax ~ no window will be used. ++norestore Do not include this terminal window in a session file. + + *term++shell* ++shell Instead of executing {command} directly, use a shell, like with `:!command` *E279* {only works on Unix and MS-Windows} + The resulting command will look like + 'shell' 'shellcmdflag' [command] + Other options related to `:!command` + have no effect. ++kill={how} When trying to close the terminal window kill the job with {how}. See |term_setkill()| for the values.