gotc

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package gotc provides functions to invoke the Go toolchain.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildArchive added in v0.2.0

func BuildArchive(root, src, target string) error

func BuildCGoHeader added in v0.2.0

func BuildCGoHeader(root, src, target string) error

func Check

func Check() error

Check that Go is installed.

func ModInit

func ModInit(modName string) error

ModInit runs the go mod init command.

func ModTidy

func ModTidy() error

ModTidy runs the go mod tidy command.

Types

type Cache

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

Cache stores the path where Go caches modules.

func NewCache

func NewCache() (*Cache, error)

NewCache reads where Go caches modules.

func (*Cache) OSPath

func (cache *Cache) OSPath(mod *module.Version) (string, error)

ModuleOSPath returns the OS path of a given module path and its version.

Jump to

Keyboard shortcuts

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