util

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Common = "common"
	Config = "config"
)
View Source
const Max = 1000

Max number of files can operate at once

Variables

This section is empty.

Functions

func ExecuteTasks

func ExecuteTasks()

func MatchTmpl

func MatchTmpl(license string, useSPDXIDs bool) (string, error)

func PrepareTasks

func PrepareTasks(paths []string, tmpl []byte, operation Operation, skipF []string, muteF bool, tmplF string)

PrepareTasks walk through the dir and add tasks into task chan TODO: optimize function args

Types

type Operation

type Operation string
const (
	Add    Operation = "add"
	Update Operation = "update"
	Remove Operation = "remove"
	Check  Operation = "check"
)

type TmplData

type TmplData struct {
	Holder  string
	Year    string
	SPDXIDs string
}

func (*TmplData) RenderTmpl

func (t *TmplData) RenderTmpl(tmpl string) ([]byte, error)

Jump to

Keyboard shortcuts

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