tpl

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Args

type Args struct {
	OS           string
	Arch         string
	Version      string
	NakedVersion string
	ExeExtension string
}

Args holds templating args

func New

func New(v string) Args

New returns populated template Args

func (Args) Interpolate

func (a Args) Interpolate(m map[string]string)

Interpolate changes some values by others

func (Args) MatchFilters

func (a Args) MatchFilters(file string, filters []string) (bool, error)

MatchFilters matches a file against a list of template filters

func (Args) Render

func (a Args) Render(t string) (string, error)

Render a passed-in template agains args

Jump to

Keyboard shortcuts

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