Posts tagged with: cli

A Guide to Embedding Static Files in Go using go:embed

4 min read

In this blog post, you will learn how to simplify the deployment and distribution of Go programs by embedding static files directly in their code using go:embed, a new directive introduced in Go 1.16. This post covers the basic syntax of the directive, its limitations, and best practices for using it effectively. By the end of this post, you will have a solid understanding of how to leverage go:embed to streamline your Go programs and improve your deployment process.

How to Authenticate CLI Using OAuth

4 min read

Are you building a CLI that needs to authenticate using OAuth? If so, you'll need to require permission for your access token using OAuth flow. In this article, we'll walk through the process of authenticating a CLI using OAuth and GitHub.