windows terminal退出时关闭窗口

terminal 默认在用 exit 退出时,如果最后一条命令出错,会显示 error code 且卡住窗口不关闭:
error-code-on-exit
想让它像 cmd 一样直接退出,参考 [1],打开 json 设置:
open-setting
open-json-setting
然后在 profiles/defaults 中加入 "closeOnExit": "always"

{
    "profiles": {
        "defaults": {
            "closeOnExit": "always"
        },
    }
}

Splitting Panes

terminal 分屏见 [4]。一些快捷键:

  • alt + shift + +/-:在右/下方创建新分屏;
  • alt + 方向健:切换分屏,类似 vim 的 ctrl + w + h/j/k/l;
  • alt + shift + 方向:调当前分屏大小;
  • ctrl + shift + w:关当前分屏;
  • ctrl + shift + p:呼出命令版面(此处「命令」是指与 terminal 这个软件相关的命令)。

References

  1. Terminal hangs on exit with ‘process exited with code 127’ message #4573
  2. How to Add or Remove “Open in Windows Terminal” context menu in Windows 10
  3. Add “open Windows terminal here” into right-click context menu #1060
  4. Panes in Windows Terminal
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值