Skip to content

CLI Overview

Welcome to the gtb CLI! ๐Ÿš€

Our command-line tool is designed to be your best friend when building powerful, well-structured Go applications. It takes the heavy lifting out of boilerplate generation, allowing you to focus on what truly matters: your unique logic.

Why use the gtb CLI?

  • Consistency: Ensures all your tools follow a standard, battle-tested structure.
  • Speed: Go from an idea to a running command in seconds.
  • HIerarchy Made Easy: Deeply nested commands? No problem. Our CLI handles the package structure and registration for you.
  • AI-Powered Autonomous Repair: Convert scripts to Go and fix errors automatically using built-in coding agents.
  • Self-Documenting: Every command you generate automatically gets its own documentation page.

Core Philosophical Principles

  1. Explicit is better than implicit: We use a Manifest (.gtb/manifest.yaml) so your project's structure is always clear and transparent.
  2. Encapsulated Logic: We separate command boilerplate from your actual implementation, making your code cleaner and easier to test.
  3. Safety First: Our templates use best practices like structured error handling and context propagation by default.

Getting Started

To install the CLI tool, run:

go install github.com/phpboyscout/gtb@latest

Once installed, you can explore the available generation tools:

gtb generate --help

Or if you are working directly in this repository:

go run main.go generate --help

In the following sections, we'll dive into how to scaffold a new project, grow it with hierarchical commands, and keep it documented with our AI-powered tools. Let's build something amazing! โœจ