Streamline project setup and management across any tech stack.
Project details
Genesis simplifies the process of starting and managing projects through an intuitive scaffolding and task runner interface. With support for multiple tech stacks, customizable templates, and a focus on convention over configuration, Genesis is designed for developers looking for efficiency and flexibility in their workflow.
Genesis is a robust project scaffolding and task runner tool designed to simplify the initiation and management of projects across various technology stacks with a consistent and unified interface.
genesis new my-project --template https://github.com/example/template-go-cli
genesis new my-project -t https://github.com/example/template-go-cli -y
genesis run test
genesis run build
Template Definition: Define project variables and hooks using the template.toml file. An example structure is shown below:
version = "1.0"
[vars]
description = { prompt = "Enter a short project description:" }
author = { prompt = "Enter the author's name:" }
[hooks]
post = [
"go mod tidy",
"git init",
"git add .",
"git commit -m 'Initial commit from Genesis'"
]
Task Definition: Set up project-specific tasks in the genesis.toml file. Here’s an example:
version = "1.0"
[project]
template_url = "https://github.com/user/go-cli-template"
template_version = "v1.0.2"
[tasks]
test = { description = "Run all unit tests.", cmd = "go test ./..." }
build = { description = "Build the application binary.", cmd = "go build -o myapp main.go" }
lint = { description = "Lint the source code.", cmd = "golangci-lint run" }
To create a custom template, establish a Git repository containing:
template.toml file defining variables and hooks..tmpl that will be processed using the defined variables.Example template structure:
my-template/
├── .gitignore.tmpl
├── main.go.tmpl
├── README.md.tmpl
└── template.toml
Genesis serves as a valuable tool for developers seeking to enhance their productivity while managing various project types succinctly.
Comments
0Start the conversation
Share the first comment.