Windows Terminal

windows terminal这个终端很好用,这里记一下

windows terminal需要通过microsoft store下载。

将microsoft store从网络沙盒中移除,以便使用代理加速

win+r运行regedit

HKEY_CURRENT_USER\Software\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\AppContainer\Mappings

找到name为microsoft store的项目,记下SID,然后在管理员权限的powershell中运行:

 CheckNetIsolation.exe loopbackexempt -a -p=S-1-15-2-1609473798-1231923017-684268153-4268514328-882773646-2760585773-1760938157

更多请查看知乎专栏

安装windows terminal

通过microsoft store安装

配置文件

{
    "$help": "https://aka.ms/terminal-documentation",
    "$schema": "https://aka.ms/terminal-profiles-schema",
    "actions": [
        {
            "command": {
                "action": "sendInput", // 用于在coding agent cli中换行
                "input": "\u001b\r"
            },
            "id": "User.SendEscEnter"
        },
        {
            "command": {
                "action": "copy",
                "singleLine": false
            },
            "id": "User.copy"
        },
        {
            "command": "paste",
            "id": "User.paste"
        },
        {
            "command": "find",
            "id": "User.find"
        },
        {
            "command": {
                "action": "splitPane",
                "split": "auto",
                "splitMode": "duplicate"
            },
            "id": "User.splitPane"
        }
    ],
    "copyFormatting": "none",
    "copyOnSelect": false,
    "defaultProfile": "{8c18a300-7369-4c14-ab39-391b1cd9bc93}",
    "disabledProfileSources": [
        "Windows.Terminal.VisualStudio",
        "Windows.Terminal.Azure"
    ],
    "keybindings": [
        {
            "id": "User.copy",
            "keys": "ctrl+c"
        },
        {
            "id": "User.paste",
            "keys": "ctrl+v"
        },
        {
            "id": "User.find",
            "keys": "ctrl+shift+f"
        },
        {
            "id": "User.splitPane",
            "keys": "alt+shift+d"
        },
        {
            "keys": "shift+enter",
            "id": "User.SendEscEnter"
        }
    ],
    "newTabMenu": [
        {
            "type": "remainingProfiles"
        }
    ],
    "profiles": {
        "defaults": {},
        "list": [
            {
                "guid": "{64525207-991d-5a52-96b2-a69a5453f28c}",
                "hidden": false,
                "name": "Debian",
                "source": "Microsoft.WSL"
            },
            {
                "elevate": false,
                "guid": "{574e775e-4f2a-5b96-ac1e-a2962a402336}",
                "hidden": false,
                "name": "PowerShell",
                "source": "Windows.Terminal.PowershellCore"
            },
            {
                "commandline": "%SystemRoot%\\System32\\WindowsPowerShell\\v1.0\\powershell.exe",
                "elevate": true,
                "guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
                "hidden": false,
                "name": "Windows PowerShell"
            },
            {
                "commandline": "%SystemRoot%\\System32\\cmd.exe",
                "elevate": true,
                "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
                "hidden": false,
                "name": "\u547d\u4ee4\u63d0\u793a\u7b26"
            }
        ]
    },
    "schemes": [
        {
            "background": "#300A24",
            "black": "#171421",
            "blue": "#0037DA",
            "brightBlack": "#767676",
            "brightBlue": "#08458F",
            "brightCyan": "#2C9FB3",
            "brightGreen": "#26A269",
            "brightPurple": "#A347BA",
            "brightRed": "#C01C28",
            "brightWhite": "#F2F2F2",
            "brightYellow": "#A2734C",
            "cursorColor": "#FFFFFF",
            "cyan": "#3A96DD",
            "foreground": "#FFFFFF",
            "green": "#26A269",
            "name": "Ubuntu-22.04-ColorScheme",
            "purple": "#881798",
            "red": "#C21A23",
            "selectionBackground": "#FFFFFF",
            "white": "#CCCCCC",
            "yellow": "#A2734C"
        }
    ],
    "themes": [],
    "warning.largePaste": false
}