✨ A guideline for configuring your IDE (vscode and vim/neovim) and your development environment on Windows (WindowsTerminal, PowerShell) and Linux (wsl, tmux, zsh).
📄中文文档
-
Install apps by Microsoft Store
- Windows Terminal
- PowerShell
- PowerToys
- TranslucentTB
-
Install apps by Scoop
scoop install -y 7zip git aria2
-
Install NerdCodeProPlus font
-
Configure
%USERPROFILE%\.gitconfig
[user] name = Your Name email = u[email protected] [merge] tool = vimdiff [mergetool "vimdiff"] path = nvim
-
Configure
%USERPROFILE%\.ssh\config
Host github.com HostName github.com Port 22 User git IdentitiesOnly yes IdentityFile ~/.ssh/github.key
-
Configure Windows Terminal settings.json
-
Configure PowerShell $PROFILE
# install dependencies before copy config file scoop install lsd fzf Set-ExecutionPolicy Bypass -Scope Process -Force; Invoke-Expression ((New-Object System.Net.WebClient).DownloadString('https://ohmyposh.dev/install.ps1')) Install-Module PSReadLine Install-Module PSFzf Install-Module ZLocation Install-Module posh-git Install-Module git-aliases -AllowClobber
Tips: The keybindings refer to zsh
-
Install dual-key-remap to remap CapsLock to Escape when pressed alone and Ctrl when pressed with other keys.
Tips: Don't forget to enable administrator access or else it doesn't work on administrator applications.
-
Set your system by press
Win
+I
-
Install the cursor theme you like
-
Install WSL2
# in admin wsl --install wsl --update
-
Install ArchWSL
Tips: ArchWSL is optional, if you like ArchLinux, you can set it as the default distro for wsl by
wsl -s Arch
, or you can just use ubuntu. -
Limit the memory usage of WSL2, create file
%UserProfile%\.wslconfig
with following content[wsl2] memory=6GB swap=0
-
Execute the shell script in wsl to configure all the things
# in wsl curl -Lo init.sh https://github.com/mrbeardad/MyIDE/raw/master/init.sh # execute it directly, don't `bash ./init.sh` ./init.sh
Tips: You can open init.sh to have a look, all configuretion is at the end of script, You can extract thme alone.
-
Install VSCode and Neovim
scoop install vscode neovim ripgrep make rust go python nodejs flutter
Tips: The packages after make are optional.
-
Install Visual Studio
Tips: Check the option of clang and add
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\Llvm\x64\bin
andC:\Program Files\Microsoft Visual Studio\2022\Community\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin
to environment variablePATH
-
Configure Neovim
- Install nightly version of LunarVim
- Copy config.lua to
%LOCALAPPDATA%\lvim\
- Copy init.vim to
%LOCALAPPDATA%\nvim\
- Run
nvim.exe
to install plugins automatically
-
Configure VSCode
- Copy lastSyncextensions.json to
%APPDATA%\Code\User\sync\extensions\
- Copy settings.json and keybindings.json to
%APPDATA%\Code\User
- Launch VSCode to install plugins automatically
Tips: VSCode's config is depend on Neovim's config
- Copy lastSyncextensions.json to
Lang | Language Server | Linter | Formatter | Syntax | Snippets | Debugger | Build | Doc | Test | Prof |
---|---|---|---|---|---|---|---|---|---|---|
C++ | clangd | clang-tidy | clang-format | - | - | lldb | CMake | Doxygen | gtest | gperftools |
Go | gopls | golangci-lint | gofmt | - | - | delve | go-build | swag | testify | go-prof |
Python | pyright | pylint, flake8 | black | - | - | - | - | - | - | - |
JavaScript | tsserver | eslint | eslint | - | - | - | - | - | - | - |
HTML | - | tidy | prettier | - | - | - | - | - | - | - |
CSS | - | stylelint | prettier | - | - | - | - | - | - | - |
Markdown | - | markdownlint | prettier | - | - | - | - | - | - | - |
Other references: