Skip to content

Instantly share code, notes, and snippets.

@sumeet
Created July 17, 2024 17:11
Show Gist options
  • Save sumeet/8f3460b344e8c2c20872e2bfff2e7cb5 to your computer and use it in GitHub Desktop.
Save sumeet/8f3460b344e8c2c20872e2bfff2e7cb5 to your computer and use it in GitHub Desktop.
## Lab 0: Installation (15-30 minutes)
- [ ] Goals:
- Get development environment set up on computer.
- Get IntelliSense and IDE support working.
- Get the formatter working
- Code and run our first Hello, World!
- [ ] Install Go toolchain
- For what we're doing, version shouldn't matter (as long as it supports generics >= 1.18)
- Linux: Through OS package manager (apt / yum / pacman / etc.)
- Mac: Can be installed through brew: `brew install golang`
- Windows: Scoop / Chocolatey or...
- Just download binary / installer from the official website
- [ ] Recommended editors
- VSCode
- Go Extension
- JetBrains Goland / IntelliJ IDEA Ultimate Edition
- Both have EAP (beta) versions that are free
- Other editors: (Neo)Vim / Emacs / Sublime / etc.
- You already know what you're doing
- [ ] Set up the formatter, and set it to `goimports`
- [ ] package main, etc etc etc. Copy the Hello, World off my screen
- [ ] `go run main.go`
- [ ] Try changing Println to Printlnx. You should see an error in the editor
- [ ] Try messing up the indentation
- [ ] Remove `import fmt`
- [ ] Remember to set editor to indent with tabs instead of spaces
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment