win-web-setup

Instructions to setup and configure dev tools on windows

MIT License

Stars
5
Committers
1

Web Developer Setup for Windows 11

Instructions on how to set up and configure developer tools on windows.

This instruction uses the winget tool, which is only supported on Windows 10 1709 (build 16299) or later at this time. The winget tool will not be available until you have logged into Windows as a user for the first time, triggering Microsoft Store to register Windows Package Manager as part of an asynchronous process. If you have recently logged in as a user for the first time and find that winget is not yet available, you can open PowerShell and enter the following command to request this winget registration: Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.

Quick Setup

  1. Install and/or update the Microsoft App Installer
  2. Win + R (Run)
cmd /c curl https://raw.githubusercontent.com/toshydev/win-web-setup/main/setup.bat > %userprofile%\setup.bat && %userprofile%\setup.bat
  1. Configure Windows Terminal
  1. Install Apps
    Run in Windows Terminal as Administrator:
& ([scriptblock]::Create((irm https://raw.githubusercontent.com/toshydev/win-web-setup/main/setup-win.ps1)))
  1. Configure Git & GitHub
    Run in Windows Terminal:
& ([scriptblock]::Create((irm https://raw.githubusercontent.com/toshydev/win-web-setup/main/setup-git-win.ps1)))

Windows Package Manager

Docs

The winget command line tool enables users to discover, install, upgrade, remove and configure applications on Windows 10 and Windows 11 computers. This tool is the client interface to the Windows Package Manager service.

Install

The winget tool is part of the Microsoft App Installer. If it's already installed, make sure it is updated with the latest version.

Windows Terminal & PowerShell 7

Docs

Windows Terminal is a modern host application for the command-line shells you already love, like Command Prompt, PowerShell, and bash (via Windows Subsystem for Linux (WSL)). Its main features include multiple tabs, panes, Unicode and UTF-8 character support, a GPU accelerated text rendering engine, and the ability to create your own themes and customize text, colors, backgrounds, and shortcuts.

Docs

PowerShell is a cross-platform task automation solution made up of a command-line shell, a scripting language, and a configuration management framework. PowerShell runs on Windows, Linux, and macOS.

Install

To install Windows Terminal & PowerShell 7, run this .bat script in Windows CMD:

  • Open CMD with the key-combination: WIN + R, type cmd and press ENTER
  • paste and run this cURL command in CMD:
curl https://raw.githubusercontent.com/toshydev/win-web-setup/main/setup.bat > %userprofile%\setup.bat && %userprofile%\setup.bat

(The script installs Windows Terminal and PowerShell 7 with the winget tool you installed in the first step.)

Configuration (Do not skip)

Set Windows Terminal as your default Terminal and PowerShell 7 as the default profile by following these two simple steps:

You can skip the rest of the customization (Add new profile, etc.)

Dev Tools

Now that you have a brand new terminal you can install the most important applications:

Install

With the winget tool you can easily install all these tools at once. Open Windows Terminal as Administrator and paste and run this script:

& ([scriptblock]::Create((irm https://raw.githubusercontent.com/toshydev/win-web-setup/main/setup-win.ps1)))

The script installs the apps from the list as well as the eslint package for error linting in VSC.

Error

If you encounter this error: image You need to temporarily allow PowerShell to run unsigned scripts by running theses commands:

Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope Process

Git & GitHub

To be able to connect your remote GitHub repositories with your local projects you need to set up your Git config and authenticate with the GitHub CLI.

Configuration

Make sure to open Windows Terminal as Administrator and paste and run this script:

& ([scriptblock]::Create((irm https://raw.githubusercontent.com/toshydev/win-web-setup/main/setup-git-win.ps1)))

The script sets your Git username and email globally, creates a new SSH key, adds the key to your SSH agent and uses these settings with the GitHub CLI to authorize you without a password.

Error

If you encounter this error: image You need to temporarily allow PowerShell to run unsigned scripts by running theses commands:

Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope Process

The End

ATTENTION If you have set the Execution Policy to unrestricted earlier you should reset it to its initial value by running this command:

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope Process

Good Work! You did it! Nothing can stop you! Happy Hacking

Please leave a star if this instruction helped you.

If an instruction didn't work as it should, open an issue in the Issues section.

Related Projects