Let's wrap up learning about the #Golang CLI

Go CLI; Help, Docs, and Miscellany

2021-09-16 #30years30threads 16/30

A thread🧵⬇
/1 Go Help

When diving into the #Golang CLI `go help` is your best friend.

It contains very detailed reports of each sub-component in the CLI.
(Think man pages, but just for go)

You can see all top-level options with `go help`, then dive deeper with `go help <topic>`.
/2 Go Doc

This is the go-to tool for exploring the #Golang standard library and other packages.

With Go Doc you can lookup docs for;
* packages
* consts
* funcs
* types
* vars
* structs
* more...

e.g. `go doc net/http.StatusOK` to see HTTP status consts defined in net/http.
/3 Go Get

This is the #Golang package manager. You can use any github (or similar) URL that points to a Go package to download (and install) that package to your system.

e.g. `go get github.com/magefile/mage`

Use this to install dependencies (before modules) and system tools.
/4 Go Environment

#Golang tools frequently depend on the environment variables you set.

You can check or modify these environment variables with `go env`.

I've used this many times to makes sure my proxy settings are correct at work.
/5 Go Generate

#Golang has a built-in way to generate code before compiling it.

When used in conjunction with a package like `github.com/josharian/impl` go generation can be used to stub out entire packages quickly.

Check out `go help generate` for more details.
/6 Go Bug

Ever found a bug in #Golang?

Yeah me neither, but if I do, I can report it directly from the command line with `go bug`.

This will create a github ticket with all your environment details to help the go team debug the issue better.
/EO🧵

There we go; we've wrapped up learning about the #Golang CLI with Help, Docs, and More.

If you have any questions, or just want to nerd out, let's continue the conversation. I'm @cctechwiz, and my DMs are open.

Subscribe to blog.cctechwiz.com for similar articles.

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Josh Maxwell

Josh Maxwell Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @cctechwiz

18 Sep
⭐ PPV ⭐
My current Life Operating System

PPV stands for Pillars, Pipelines, and Views.

It is an incredible productivity system created by @augustbradley.

I have been using it for about a year now. Let's look at the basics.

2021-09-18 #30years30threads 18/30

A thread🧵⬇
/1 The Goal
The whole PPV system is about integrating systems to gain better focus and alignment, with knowledge resurfacing at the right time.

With PPV I tie my tasks to my goals, habits, and values and track my overall progress regularly.
/2 Pillars
Organize by Cross-Cutting Life Segments

This is where you define what categories your life involves.

For me this includes;
* Mind Expansion
* Health, Fitness & Sleep
* Husband, Father & Family
* Finances & Admin
* Hobbies & Entertainment
* Job & Career
Read 9 tweets
17 Sep
It's Follow Friday: Golang Edition! 🤩

Check below for who you should follow for A+ #Golang content on various platforms.

Please feel free to jump in and add your own! I'm always looking for more quality sources!

2021-09-16 #30years30threads 16/30

A #FollowFriday thread🧵⬇
Read 7 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!

:(