Skip to content

Instantly share code, notes, and snippets.

@nsticco
Last active December 21, 2023 20:43
Show Gist options
  • Save nsticco/aa02b907f1aae06e3f9789e90f52b922 to your computer and use it in GitHub Desktop.
Save nsticco/aa02b907f1aae06e3f9789e90f52b922 to your computer and use it in GitHub Desktop.
bootstrap-windows-vscode
##########################################################################################
# Setup VS Code
##########################################################################################
Write-Output "Make sure Chocolatey is installed..."
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
Write-Output "Install vscode..."
choco install -y vscode
# Write-Output "Replacing VS Code settings..."
# Invoke-WebRequest -Uri "https://gist.github.com/nsticco/1b32f3b0f630df637436e407a8ba626d/raw" -OutFile "$HOME\AppData\Roaming\Code\User\settings.json"
Write-Output "Download coding fonts with ligatures..."
git clone https://github.com/lemeb/a-better-ligaturizer.git $HOME\a-better-ligaturizer
Write-Output "Installing coding fonts..."
$Fonts = Get-ChildItem -Path $HOME\a-better-ligaturizer\output-fonts\ -Include ('*.fon','*.otf','*.ttc','*.ttf') -Recurse
$ShellAppFontNamespace = 0x14
$ShellApp = New-Object -ComObject Shell.Application
$FontsFolder = $ShellApp.NameSpace($ShellAppFontNamespace)
foreach ($Font in $Fonts) {
Write-Verbose -Message ('Installing font: {0}' -f $Font.BaseName)
$FontsFolder.CopyHere($Font.FullName)
}
Write-Output "Installing VS Code extensions..."
code --install-extension github.copilot `
--install-extension daylerees.rainglow `
--install-extension secanis.jenkinsfile-support `
--install-extension ms-python.python `
--install-extension esbenp.prettier-vscode `
--install-extension bradgashler.htmltagwrap `
--install-extension dsznajder.es7-react-js-snippets `
--install-extension dunstontc.vscode-docker-syntax `
--install-extension formulahendry.code-runner `
--install-extension hashicorp.terraform `
--install-extension 4ops.terraform `
--install-extension eamodio.gitlens `
--install-extension vscode-icons-team.vscode-icons `
--install-extension zxh404.vscode-proto3 `
--install-extension ms-vscode.vs-keybindings `
--install-extension ms-vscode.cpptools `
--install-extension twxs.cmake `
--install-extension ms-vscode.cmake-tools `
--install-extension ms-azuretools.vscode-docker `
--install-extension dtsvet.vscode-wasm `
--install-extension Worlds.verse `
--install-extension ms-vscode.powershell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment