Terminal Setup
This is a quick tutorial on getting the basics of a useful Terminal environment for development on a Windows machine.
Install Windows Terminal
Install the Windows Terminal and set it as Default https://aka.ms/terminal
Modify Security Settings to allow Shell to access files
Windows Security > Virus & Threat Protection > Manage Settings > Allow an app through Controlled Folder Access
Install Some CLI Tools
PowerShell 7
Get PS7 and enhanced auto-complete
winget install Microsoft.Powershell
git
winget install Git.Git
Text Editors
Neovim: A quick, lightweight text editor, helpful for fzf preview and small file edits
Bat: A text file reader with syntax highlighting NodeJS: Used by some vim plugins
winget install neovim
winget install bat --source winget
winget install OpenJS.NodeJS
Neovim Configurations
First, install the plugin manager vim-plug
with the command
Invoke-WebRequest -useb https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim | New-Item "$env:LOCALAPPDATA/nvim-data/site/autoload/plug.vim" -Force
Create a config file at ~\AppData\Local\nvim\init.vim
, populate it with some preferences like
set writebackup
set ignorecase
set number
call plug#begin()
Plug 'junegunn/vim-easy-align'
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install -all' }
Plug 'junegunn/fzf.vim'
Plug 'github/copilot.vim'
Plug 'folke/tokyonight.nvim'
call plug#end()
let g:fzf_vim = {}
let g:fzf_vim.preview_window = ['hidden,right,70%', 'ctrl-/']
colorscheme tokyotonight
Open nvim and run :PlugInstall
. Close and reopen nvim and you should be able to run commands like :Files
Also, to setup Copilot run :Copilot setup
fzf
Fuzzy finder, a useful tool for quickly maneuvering around and searching through files
winget install fzf
Profile addition to customize, this variable is also used by fzf.vim
$env:FZF_DEFAULT_OPTS="-i -m --preview-window='right:65%' --preview='bat --theme=OneHalfDark --color=always {}'";
Oh My Posh
winget install JanDeDobbeleer.OhMyPosh --source winget
oh-my-posh font install # MesloLGM Nerd Font
Profile additions to customize
oh-my-posh init pwsh --config "$env:POSH_THEMES_PATH\clean-detailed.omp.json" | Invoke-Expression;
Helpful Modules
Set-PSRepository -Name PSGallery
Install-Module PSReadLine
Install-Module Az -AllowClobber
Install-Module SqlServer -AllowClobber
Install-Module DbaTools
Install-Module posh-git
Profile additions to enable
Import-Module PSReadLine
Import-Module posh-git