目錄
文章目錄
- 目錄
- 插件
- 配置
- 設置代碼不顯示 git 提示 "xxx months ago | 1 author"
- 設置打開項目不自動選擇 CMakeLists
插件
以下插件為 C++ 開發偏好設置。
- C/C++
- CMake
- CMake Tools
- GitLens
- Remote Development
- Remote Explorer
配置
設置代碼不顯示 git 提示 “xxx months ago | 1 author”
安裝 GitLens 之后,代碼文件中顯示 “xxx months ago, | 1 author” 這樣的信息,就像這樣:
個人感覺影響閱讀,關閉方法:
左側 GitLens 插件 —— GitLens Settings —— Git CodeLens —— 取消勾選即可。
設置打開項目不自動選擇 CMakeLists
在打開工程時會讓選擇一個 CMakeLists 文件,如果不選定,每次打開都會提示,如果選定,每次打開都會自動加載這個選定的 CMakeLists 文件。個人感覺不好用,不如讓我自己選擇加載哪個 CMakeLists ,關閉的方法:
左側 CMake —— 點擊窗口上的設置圖標(Open CMake Tools Extension Settings)—— Cmake: Configure On Open —— 取消勾選即可。
另外,在項目根目錄下的 .vscode/settings.json
中可以配置 CMake 的根目錄:
settings.json:
{"cmake.sourceDirectory": "/Users/boss/Desktop/codes/cpp","files.associations": {"optional": "cpp"}
}