Skip to content
0:00 / 0:00

#cli#cobra#go

GopherCon 2019: Design Command-Line Tools People Love - Carolyn Van Slyck

Gopher Academy

41K subscribers • 9 videos on Hallway

YouTube
  • Recommended by 1 person: 1 in engineering communities.
  • Presented by Carolyn Van Slyck

Intermediate. Assumes working knowledge.

12K views7 years ago1 recommendation

Tools and practiceProgramming languagesGoThe shell and command lineDesign patterns

Carolyn Van Slyck explains how to design, structure, and test user-friendly command-line tools in Go.

It is a joy to build command-line tools that are not only easy to learn, but that other developers are willing to maintain. Often a team's engineering efforts are spent on the backend, while the cli doesn't receive the same level of attention. This can result in hard-to-test tools and dumping maintenance of them to whoever most recently joined the team. Learn how to take full advantage of popular Go libraries, structure your Go code to improve reuse and testability, publish binaries, and of course design your commands to be user friendly.

Why it's here

1 person recommends this

What people say. Recommended as a great resource for learning how to design and structure CLI tools.

u/inthehackin r/rust • Recommends

On “CLI as separate package or feature?”

…u library. with such a design, you can have features in both you library and you cli if needed. and one big point here is to make your library not depending on you cli but the opposite (see inversion of control and dependency injection, like in clean architecture). finally, if you want to design a great cli, I can't encourage you more to look at link to this video…