Skip to content

Commit

Permalink
VSCode install, brew, wsl -d for distribution
Browse files Browse the repository at this point in the history
  • Loading branch information
Reecepbcups committed Oct 30, 2024
1 parent 3dc9e97 commit deddec2
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 21 deletions.
50 changes: 30 additions & 20 deletions docs/versioned_docs/version-v0.50.x/01-setup/01-system-setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,25 +26,30 @@ If you do not have these components installed, follow the instructions below to

## Install Dependencies

Install [VSCode](https://code.visualstudio.com/download) if you do not already have a file editor. Once installed, the following extensions are useful
- [Golang Syntax Highlighting](https://marketplace.visualstudio.com/items?itemName=golang.Go)
- [Protobuf 3 Highlighting](https://marketplace.visualstudio.com/items?itemName=zxh404.vscode-proto3)
- [Improved Errors](https://marketplace.visualstudio.com/items?itemName=usernamehw.errorlens)

<Tabs defaultValue="macos">
<TabItem value="macos" label="MacOS">

```bash
# Base
brew install make
brew install gcc
brew install wget
brew install jq
# Setup Homebrew (https://brew.sh/)
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
sudo echo 'export PATH=$PATH:/opt/homebrew/bin' >> ~/.zshrc

# Github CLI - https://github.com/cli/cli
brew install gh
gh auth login
# Base
brew install make wget jq gh gcc go

# Golang
brew install go
# (optional) Github CLI login
# gh auth login

# Docker
brew install --cask docker
open -a Docker # start docker desktop

# Start docker desktop
open -a Docker
# settings -> General -> Start Docker Desktop when you sign in to your computer
# Apply & Restart

Expand All @@ -55,32 +60,33 @@ If you do not have these components installed, follow the instructions below to
</TabItem>

<TabItem value="windows" label="Windows (WSL)" default>

```bash
# Install WSL in powershell
wsl --install
Restart-Computer
# Setup WSL Ubuntu Image
wsl.exe --install Ubuntu-24.04
wsl.exe --install -d Ubuntu-24.04
# Open wsl instance
wsl
# update and add snap if not already installed
sudo apt update && sudo apt install snapd
# Install Go (Snap)
sudo snap install go --channel=1.23/stable --classic
# Install Go (https://go.dev/wiki/Ubuntu)
sudo apt update
sudo apt install golang -y
# Install Base
sudo apt install make gcc git jq wget
sudo apt install make gcc git jq wget -y
# Install github-cli
sudo snap install gh
# Optional: Install github-cli
# sudo snap install gh
# Install docker
https://docs.docker.com/desktop/wsl/#turn-on-docker-desktop-wsl-2
# or snap:
# If you can't use snap, setup from:
# - https://docs.docker.com/desktop/wsl/#turn-on-docker-desktop-wsl-2
sudo snap install docker
# Fix versioning for interaction of commands
Expand All @@ -90,9 +96,13 @@ If you do not have these components installed, follow the instructions below to
git config --global user.email "[email protected]"
git config --global user.name "Your Name"
```

After installing VSCode and having your system setup, open a terminal and run `code` to open vscode. You can open the current directory with `code .`, where `.` in computer terms stands for the current directory.

</TabItem>

<TabItem value="ubuntu-linux" label="Linux (Ubuntu)">

<!-- markdown-link-check-disable -->
```bash
# Base
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ heighliner

## Command not found error

# If you get "command 'spawn' not found", run the following
If you get "command 'spawn' not found", run:

```bash
# Gets your operating system
Expand All @@ -62,6 +62,7 @@ esac
echo "Your operating system is: $machine"
echo -e "\nAdding the go binary location to your PATH for global access.\n\tIt will now prompt you for your password."

# Adds the location of the binaries to your PATH for global execution.
cmd='export PATH=$PATH:$(go env GOPATH)/bin'
if [ $machine == "Linux" ]; then
sudo echo "$cmd" >> ~/.bashrc && source ~/.bashrc
Expand Down

0 comments on commit deddec2

Please sign in to comment.