ffi

package
v0.0.0-...-0a43815 Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2024 License: MPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ChangedFiles

func ChangedFiles(gitRoot string, turboRoot string, fromCommit string, toCommit string) ([]string, error)

ChangedFiles returns the files changed in between two commits, the workdir and the index, and optionally untracked files

func FromWildcards

func FromWildcards(environmentMap map[string]string, wildcardPatterns []string) (map[string]string, error)

FromWildcards returns an EnvironmentVariableMap containing the variables in the environment which match an array of wildcard patterns.

func GetGlobalHashableEnvVars

func GetGlobalHashableEnvVars(envAtExecutionStart map[string]string, globalEnv []string) (*ffi_proto.DetailedMap, error)

GetGlobalHashableEnvVars calculates env var dependencies

func GetHashesForFiles

func GetHashesForFiles(rootPath string, files []string, allowMissing bool) (map[string]string, error)

GetHashesForFiles proxies to rust for hashing a given set of files

func GetPackageFileHashes

func GetPackageFileHashes(rootPath string, packagePath string, inputs []string) (map[string]string, error)

GetPackageFileHashes proxies to rust for hashing the files in a package

func GetTurboDataDir

func GetTurboDataDir() string

GetTurboDataDir returns the path to the Turbo data directory

func GlobalChange

func GlobalChange(packageManager string, prevContents []byte, currContents []byte) bool

GlobalChange checks if there are any differences between lockfiles that would completely invalidate the cache.

func Marshal

func Marshal[M proto.Message](c M) C.Buffer

Marshal consumes a proto.Message and returns a bufferfire

NOTE: the buffer must be freed by calling `Free` on it

func PreviousContent

func PreviousContent(gitRoot, fromCommit, filePath string) ([]byte, error)

PreviousContent returns the content of a file at a previous commit

func TransitiveDeps

func TransitiveDeps(content []byte, packageManager string, workspaces map[string]map[string]string, resolutions map[string]string) (map[string]*ffi_proto.LockfilePackageList, error)

TransitiveDeps returns the transitive external deps for all provided workspaces

func Unmarshal

func Unmarshal[M proto.Message](b C.Buffer, c M) error

Unmarshal consumes a buffer and parses it into a proto.Message

func VerifySignature

func VerifySignature(teamID []byte, hash string, artifactBody []byte, expectedTag string, secretKeyOverride []byte) (bool, error)

VerifySignature checks that the signature of an artifact matches the expected tag

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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