8000 GitHub - jakedt/optgen · GitHub
[go: up one dir, main page]

Skip to content
jakedtPublic
forked from ecordell/optgen

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
8272
 
 
 
 
 
 

Repository files navigation

optgen

Functional Option Generator for go

Usage

Add to tools.go

package tools

import (
	_ "github.com/ecordell/optgen"
)

Anywhere in your codebase, call optgen via go:generate

//go:generate go run github.com/ecordell/optgen . MyConfig 
package mypkg

Features

  • Detects scope and will only generate options for private members if generating in the same package
  • Detects slice and map types and creates functions to append or replace

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages

0