generators

package
v0.16.2 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2025 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Overview

Copyright © 2024-2025 Macaroni OS Linux See AUTHORS and LICENSE for the license details and contributors.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CustomGenerator added in v0.16.0

type CustomGenerator struct {
	Opts map[string]string
}

func NewCustomGenerator added in v0.16.0

func NewCustomGenerator(opts map[string]string) *CustomGenerator

func (*CustomGenerator) GetElabPaths added in v0.16.0

func (g *CustomGenerator) GetElabPaths(pkgname string) (string, string, string, string)

func (*CustomGenerator) GetOpts added in v0.16.0

func (g *CustomGenerator) GetOpts() map[string]string

func (*CustomGenerator) GetType added in v0.16.0

func (g *CustomGenerator) GetType() string

func (*CustomGenerator) Process added in v0.16.0

func (g *CustomGenerator) Process(atom *specs.AutogenAtom) (*map[string]interface{}, error)

Retrieve metadata and all availables tags/releases

func (*CustomGenerator) SetVersion added in v0.16.0

func (g *CustomGenerator) SetVersion(atom *specs.AutogenAtom, version string,
	mapref *map[string]interface{}) error

type CustomGeneratorValues added in v0.16.0

type CustomGeneratorValues struct {
	Name      string                  `json:"name" yaml:"name"`
	Atom      *specs.AutogenAtom      `json:"atom,omitempty" yaml:"atom,omitempty"`
	Values    *map[string]interface{} `json:"vars,omitempty" yaml:"vars,omitempty"`
	Artefacts []*specs.AutogenAsset   `json:"artefacts,omitempty" yaml:"artefacts,omitempty"`
}

func ReadVars added in v0.16.0

func ReadVars(file string) (*CustomGeneratorValues, error)

func (*CustomGeneratorValues) WriteYamlFile added in v0.16.0

func (v *CustomGeneratorValues) WriteYamlFile(f string) error

type DirlistingGenerator

type DirlistingGenerator struct {
	RestGuard *guard.RestGuard
}

func NewDirlistingGenerator

func NewDirlistingGenerator() *DirlistingGenerator

func (*DirlistingGenerator) GetType

func (g *DirlistingGenerator) GetType() string

func (*DirlistingGenerator) Process

func (g *DirlistingGenerator) Process(atom *specs.AutogenAtom) (*map[string]interface{}, error)

func (*DirlistingGenerator) SetVersion

func (g *DirlistingGenerator) SetVersion(atom *specs.AutogenAtom, version string,
	mapref *map[string]interface{}) error

type Generator

type Generator interface {
	Process(atom *specs.AutogenAtom) (*map[string]interface{}, error)
	GetType() string
	SetVersion(atom *specs.AutogenAtom, v string, mapref *map[string]interface{}) error
}

func NewGenerator

func NewGenerator(t string, opts map[string]string) (Generator, error)

type GithubGenerator

type GithubGenerator struct {
	Client *github.Client
}

func NewGithubGenerator

func NewGithubGenerator() *GithubGenerator

func (*GithubGenerator) GetAssets

func (g *GithubGenerator) GetAssets(atom *specs.AutogenAtom,
	release *github.RepositoryRelease,
	mapref *map[string]interface{}) ([]*specs.AutogenArtefact, error)

func (*GithubGenerator) GetType

func (g *GithubGenerator) GetType() string

func (*GithubGenerator) Process

func (g *GithubGenerator) Process(atom *specs.AutogenAtom) (*map[string]interface{}, error)

func (*GithubGenerator) SetClient

func (g *GithubGenerator) SetClient(c *github.Client)

func (*GithubGenerator) SetVersion

func (g *GithubGenerator) SetVersion(atom *specs.AutogenAtom, version string,
	mapref *map[string]interface{}) error

type NoopGenerator

type NoopGenerator struct{}

func NewNoopGenerator

func NewNoopGenerator() *NoopGenerator

func (*NoopGenerator) GetType

func (g *NoopGenerator) GetType() string

func (*NoopGenerator) Process

func (g *NoopGenerator) Process(atom *specs.AutogenAtom) (*map[string]interface{}, error)

func (*NoopGenerator) SetVersion

func (g *NoopGenerator) SetVersion(atom *specs.AutogenAtom, version string,
	mapref *map[string]interface{}) error

type PypiGenerator added in v0.13.0

type PypiGenerator struct {
	RestGuard *guard.RestGuard
}

func NewPypiGenerator added in v0.13.0

func NewPypiGenerator() *PypiGenerator

func (*PypiGenerator) GetType added in v0.13.0

func (g *PypiGenerator) GetType() string

func (*PypiGenerator) Process added in v0.13.0

func (g *PypiGenerator) Process(atom *specs.AutogenAtom) (*map[string]interface{}, error)

func (*PypiGenerator) SetVersion added in v0.13.0

func (g *PypiGenerator) SetVersion(atom *specs.AutogenAtom, version string,
	mapref *map[string]interface{}) error

Jump to

Keyboard shortcuts

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