Skip to content

pranay101/GoForge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

8 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸš€ GoForge

Fast, production-ready Go Project starter

✨ Features

  • πŸ“¦ Cross-Platform - Works on Windows, macOS, and Linux
  • ⚑ Fast Setup - One-command installation and execution
  • πŸ—οΈ Go Modules - Uses go mod for dependency management
  • πŸ“‚ Auto-Generated Project - Creates main.go, go.mod, and more
  • 🌍 Environment Variable Support - Reads from .env if available
  • 🐳 Docker Support - Optional containerized execution

πŸ“₯ Installation & Setup

πŸ”§ Prerequisites

Ensure you have the following installed:

πŸš€ Quick Start

Run the setup script to initialize your project:

chmod +x setup.sh  # Give execute permission (Linux/macOS)
./setup.sh         # Run the script

For Windows (Git Bash), use:

bash setup.sh

πŸ“ Project Structure

GoForge/  
│── main.go           # Entry point of the application  
│── go.mod            # Go module dependencies  
│── .env              # Environment variables (if applicable)  
│── Dockerfile        # Docker containerization (Optional)  
│── setup.sh          # Automated project setup script  
└── README.md         # Documentation  

πŸ“œ Running the Project

πŸƒ Run Locally

go run main.go

or build and execute:

go build -o app main.go
./app

🐳 Run with Docker

docker build -t GoForge .
docker run -p 8080:8080 GoForge

Sure! Here’s a shorter version of the steps to create your own Go module:


πŸ“¦ Creating Your Own Go Module

Create a package

./forge-module.sh

🌍 Environment Variables

If a .env file exists, it will be loaded automatically.

Example .env:

PORT=8080
APP_ENV=production

πŸ“‘ API Endpoints

Method Endpoint Description
GET / Returns "Hello, Go App!"

πŸ› οΈ Customization

Modify main.go to fit your application needs. You can add routes, database connections, logging, and more!


About

Fast, production-ready Go starter

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages