singlegenerator

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 21, 2021 License: MIT Imports: 8 Imported by: 4

Documentation

Overview

Package singlegenerator defines the main function for only a single code generator.

For example, if example.org/mockgen is a generator package, all that is needed to define a standalone tool is a file, example.org/findbadness/cmd/mockgen/main.go, containing:

     // The mockgen command runs a code generator.
	package main

	import (
		"example.org/mockgen"
		"github.com/gostaticanalysis/singlegenerator"
	)

	func main() { singlegenerator.Main(mockgen.Generator) }

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Main

func Main(g *codegen.Generator)

Main is the main function for a code generation command for a single generator. It is a wrapper of singlechecker.Main. See golang.org/x/tools/go/analysis/singlechecker.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL