zoukankan      html  css  js  c++  java
  • Configure VSCode

    更换 vscode terminal 为 Cygwin

    https://code.visualstudio.com/docs/editor/integrated-terminal
    
    Can I use Cygwin's shell with the terminal on Windows?
    Yes, to use the Cygwin shell, you will first need to install the chere package and then add the following settings to your settings.json file:
    
    "terminal.integrated.shell.windows": "C:\Windows\System32\cmd.exe",
    "terminal.integrated.shellArgs.windows": ["/k", "C:\cygwin64\Cygwin.bat"]
     
    note: /K shouldn't be ignored , this arg will tell cmd to stay in Cygwin after Cygwin executed instead of quit imidiatly

    in short

    Setp 1: well install and config your cygwin application

    Step 2: open settings,json from VSCode by accessing file > preferences > setting   or open setting by type  Ctl +`

                 after setting page opened, searching by key word shell , you will see a hyperlink "Edit in Settings.json"

                 click on the hyper link to open the settings.json

                 put the following configuration in the file, save and restart VSCode

    "terminal.integrated.shell.windows": "C:\Windows\System32\cmd.exe",
    "terminal.integrated.shellArgs.windows": ["/k", "C:\cygwin64\Cygwin.bat"]

    Step 3: open VSCode , open a terminal by type a shortcut  Ctl+shif +or by accessing to the main menu terminal > New Terminal

    Step 4: update shortcut for terminal

                navigate to keybindings setting by type shortcut ctrl+shift+p search by keyboard, cick on Keyboard Shortcuts Reference and click on {} on the right up corner

               and after keybinding.json presented, then add the following shortcut into keybingding.json

                

    // Place your key bindings in this file to override the defaults
    [
        {
            "key": "ctrl+tab",
            "command": "workbench.action.terminal.focusNext", // 切换到下一个终端 
            "when": "terminalFocus"
        },
        {
            "key": "ctrl+t",
            "command": "workbench.action.terminal.new", // 打开新的终端
            "when": "terminalFocus"
        },
        {
            "key": "ctrl+1",
            "command": "workbench.action.terminal.focusAtIndex1", // 打开终端1
            "when": "terminalFocus"
        },
        {
            "key": "ctrl+2",
            "command": "workbench.action.terminal.focusAtIndex2",
            "when": "terminalFocus"
        },
        {
            "key": "ctrl+3",
            "command": "workbench.action.terminal.focusAtIndex3",
            "when": "terminalFocus"
        },
        {
            "key": "ctrl+4",
            "command": "workbench.action.terminal.focusAtIndex4",
            "when": "terminalFocus"
        },
        {
            "key": "ctrl+alt+m",
            "command": "workbench.action.toggleMaximizedPanel"
        },

    {
            "key": "ctrl+f5",
            "command": "workbench.action.reloadWindow",
            "when": "editorTextFocus"
        }
    
    
    ]

     Step 5: configure VSCode to show special characters

                 add the following settings to settings.json and reload setting.json    

    "editor.renderControlCharacters": true,
    "editor.renderWhitespace": "all"

    step 6:  change column select to Alt+{mouse select}  refer to this page

    reference document

    https://code.visualstudio.com/docs/editor/integrated-terminal

    https://www.cnblogs.com/fayin/p/10185447.html

    https://www.itnota.com/reassign-shortcut-key-column-selection-visual-studio-code/

    转载请注明出处, 更多博文请访问https://www.cnblogs.com/guoapeng/
  • 相关阅读:
    如何设置Xcode模拟器地图的当前位置
    序列化框架MJExtension详解 + iOS ORM框架
    ios 容错处理JKDataHelper和AvoidCrash
    2017.5.3最新申请公司开发者账号整个流程(包括邓白氏申请详细流程带截图)
    详细分享UICollectionView的自定义布局(瀑布流, 线性, 圆形...)
    Mac系统安装和配置tomcat步骤详解
    Mac下intellij IDEA新建javaweb项目
    Apple Mach-O Linker Warning 警告解决办法
    项目适配iOS9遇到的一些问题及解决办法(更新两个小问题)
    iOS 中 延迟操作四种方式
  • 原文地址:https://www.cnblogs.com/guoapeng/p/11039082.html
Copyright © 2011-2022 走看看