https://github.com/9dl/gobuilder
CLI Tool for Automating the Compilation Process in Go
https://github.com/9dl/gobuilder
automation cli compiling golang
Last synced: 4 months ago
JSON representation
CLI Tool for Automating the Compilation Process in Go
- Host: GitHub
- URL: https://github.com/9dl/gobuilder
- Owner: 9dl
- License: mit
- Created: 2024-11-01T14:27:45.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-11-01T14:32:52.000Z (over 1 year ago)
- Last Synced: 2025-04-07T08:38:25.967Z (10 months ago)
- Topics: automation, cli, compiling, golang
- Language: Go
- Homepage:
- Size: 35.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# GoBuilder
`GoBuilder` is a Go-based CLI tool and library that compiles Go applications for multiple operating systems and architectures with ease. It automatically reads the module name from the `go.mod` file to name the output binaries, making it a convenient solution for cross-platform builds.

## Features
- **Multi-platform builds**: Automatically compiles your Go application for multiple OS/architecture pairs.
- **Dynamic naming**: Uses the module name from `go.mod` to name binaries, ensuring output files are correctly labeled by target platform.
- **Single target or full build**: Supports building for all targets or a specific OS/architecture.
**Installation**:
You can install GoBuilder using the following command:
```bash
go install github.com/9dl/GoBuilder@latest
```
## Usage
To use GoBuilder, you can build your Go applications for specific operating systems and architectures. Here’s how to do it:
1. **Build for a specific target**:
To build your Go application for a specific OS and architecture, run:
```bash
gobuilder
```
Replace `` with your desired operating system (e.g., `linux`, `windows`, `darwin`) and `` with the desired architecture (e.g., `amd64`, `386`, `arm`).
2. **Build for all targets**:
To build your Go application for all predefined targets, simply run:
```bash
gobuilder
```
### Example
Here’s an example of building a Go application for Linux AMD64:
```bash
gobuilder linux amd64
```
## License
This project is licensed under the MIT License. See the LICENSE file for details.