17. Using Go Tools

Overview

This chapter will teach you how to make use of the Go toolkit to improve and build your code. It will also help you build and improve your code using Go tools and create binaries using go build. It will show you how to clean up library imports using goimports, detect suspicious constructs with go vet, and identify race conditions in your code using the Go race detector.

By the end of this chapter, you will be able to run code with go run, format code with gofmt, automatically generate documentation using go doc, and download third-party packages using go get.

Introduction

In the previous chapter, you've learned how to produce concurrent code. Although Go makes the task of creating concurrent code much easier ...

Get The Go Workshop now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.