depsdev

package
v0.94.3 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DependenciesRelationSelf     = "SELF"
	DependenciesRelationDirect   = "DIRECT"
	DependenciesRelationIndirect = "INDIRECT"
)

Variables

This section is empty.

Functions

func Generate

func Generate(ctx context.Context, logger *slog.Logger, sqlDB *sql.DB, pw progress.Writer, httpClient *http.Client) error

func GenerateMissingData added in v0.46.0

func GenerateMissingData(ctx context.Context, logger *slog.Logger, sqlDB *sql.DB, pw progress.Writer, httpClient *http.Client) error

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(httpClient *http.Client) Client

func (*Client) GetDependencies added in v0.46.0

func (c *Client) GetDependencies(q DependenciesQuery) (resp GetDependenciesResponse, err error, notFound bool)

func (*Client) GetVersion

func (c *Client) GetVersion(q PackageVersionQuery) (resp GetVersionResponse, err error, notFound bool)

type DependenciesQuery added in v0.46.0

type DependenciesQuery struct {
	System  string
	Name    string
	Version string
}

type DependenciesRelation added in v0.46.0

type DependenciesRelation = string

type DepsDev

type DepsDev struct{}

func (*DepsDev) CreateTables

func (d *DepsDev) CreateTables(ctx context.Context, sqlDB *sql.DB) error

type GetDependenciesResponse added in v0.46.0

type GetDependenciesResponse struct {
	Nodes []struct {
		VersionKey struct {
			System  string `json:"system"`
			Name    string `json:"name"`
			Version string `json:"version"`
		} `json:"versionKey"`
		Relation DependenciesRelation `json:"relation"`
	} `json:"nodes"`
}

type GetVersionResponse

type GetVersionResponse struct {
	VersionKey struct {
		System  string `json:"system"`
		Name    string `json:"name"`
		Version string `json:"version"`
	} `json:"versionKey"`
	Licenses     []string `json:"licenses"`
	AdvisoryKeys []struct {
		ID string `json:"id"`
	} `json:"advisoryKeys"`
}

type PackageVersionQuery

type PackageVersionQuery struct {
	System  string
	Name    string
	Version string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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