---
title: "Discussion on \"Flags and Options in Go CLIs\" | Hashnode"
description: "Discussion on \"Flags and Options in Go CLIs\". Use Go's flag package to add --name and --count to your CLI. Covers defaults, validation, and custom help messages."
url: "https://hashnode.com/posts/go-cli-flags-flag-package/69c52008b629d2d8475ad00f"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Flags and Options in Go CLIs](https://thegoninja.hashnode.dev/go-cli-flags-flag-package?utm_source=hashnode&utm_medium=feed)

Use Go's flag package to add --name and --count to your CLI. Covers defaults, validation, and custom help messages.

Mar 26 · 8 min read · thegoninja.hashnode.dev  
Read the article

-   [#go](https://hashnode.com/tag/go)
-   [#golang](https://hashnode.com/tag/golang)
-   [#cli](https://hashnode.com/tag/cli)
-   [#flags](https://hashnode.com/tag/flags)

## Written by

[Oluwatosin Oghenewaire Thompson](https://hashnode.com/@thegoninja)

@thegoninja · Nigeria

  
[View profile](https://hashnode.com/@thegoninja)

Software Engineer

Hi, I’m Oluwatosin Thompson, a Backend Engineer specialising in Go (Golang) and passionate about creating reliable, scalable, and efficient backend systems that power great products. I’ve built and maintained production-grade services using Temporal, Prometheus, and AWS, with a strong emphasis on performance optimisation, distributed systems, and clean, maintainable code. My work reflects a balance between technical excellence and real-world business impact. I enjoy sharing my learning journey through technical writing and documenting how I solve engineering challenges. Known for being teachable, adaptable, and detail-oriented, I’m always eager to take on complex problems and deliver elegant solutions. I’m committed to engineering growth, collaboration, and continuous improvement, with a long-term goal of building impactful systems used worldwide.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
