info

package
v0.13.5 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrModuleNameNotFound = errors.New("module name not found")

Functions

func BuildName

func BuildName() (string, error)

BuildName extracts the last part of the module by splitting on `/` this last part is useful for name of the binary and other things.

func ModuleName

func ModuleName() string

ModuleName returns the full module name from go.mod, it returns empty if there is an issue reading the go.mod

func RootFolder

func RootFolder() string

RootFolder looks for the root folder by scanning from the current directory and up for the first occurrence of go.mod, if it does not find the module returns empty string.

Types

This section is empty.

Jump to

Keyboard shortcuts

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