GithubHelp home page GithubHelp logo

go-template's Introduction

Go template

Go templates for new projects

This repository is a template to make use of when creating new projects in Go. It contains scripts, Dockerfile(s) and workflows.

Four templates are provided:

Getting started

To create a new project based on one of the templates:

  1. Install gonew (if it is not already installed):
go install golang.org/x/tools/cmd/gonew@latest
  1. Download the template and create the new project:
# Assuming the project will be hosted in GitHub.
# If not replace github.com/<owner>/<repo> with the correct path.
gonew github.com/RedeployAB/go-template/templates/<name> github.com/<owner>/<repo>

Example

To create a new project based on the http-server template to a GitHub repository with the user/organization name YourUser and the project/module name myproject

gonew github.com/RedeployAB/go-template/templates/http-server github.com/YourUser/myproject

Note: The directory and files will be created in the current working directory. Given the example path development/go, running the gonew command will create the new myproject into development/go/myproject.

This will download the module, it's assets and rewrite the module name and import paths to match the new module name (project).

go-template's People

Contributors

karlgw avatar

Stargazers

平江 avatar Ben Kooijman avatar

Watchers

 avatar Risto Lavett avatar

Forkers

phenri00 zate

go-template's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.