swift

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2023 License: MIT Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewParser

func NewParser() types.Parser

Types

type LockFile

type LockFile struct {
	Object  Object `json:"object"`
	Pins    []Pin  `json:"pins"`
	Version int    `json:"version"`
}

type Object

type Object struct {
	Pins []Pin `json:"pins"`
}

type Parser

type Parser struct{}

Parser is a parser for Package.resolved files

func (Parser) Parse

type Pin

type Pin struct {
	Package       string `json:"package"`
	RepositoryURL string `json:"repositoryURL"` // Package.revision v1
	Location      string `json:"location"`      // Package.revision v2
	State         State  `json:"state"`
	StartLine     int
	EndLine       int
}

func (*Pin) UnmarshalJSONWithMetadata

func (p *Pin) UnmarshalJSONWithMetadata(node jfather.Node) error

UnmarshalJSONWithMetadata needed to detect start and end lines of deps for v1

type State

type State struct {
	Branch   any    `json:"branch"`
	Revision string `json:"revision"`
	Version  string `json:"version"`
}

Jump to

Keyboard shortcuts

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