util

package
v0.0.0-...-f8f0647 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2015 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetRootFromPackage

func GetRootFromPackage(pkg string) string

GetRootFromPackage retrives the top level package from a name.

From a package name find the root repo. For example, the package github.com/Masterminds/cookoo/io has a root repo at github.com/Masterminds/cookoo

Types

type BuildCtxt

type BuildCtxt struct {
	build.Context
}

BuildCtxt is a convenience wrapper for not having to import go/build anywhere else

func GetBuildContext

func GetBuildContext() (*BuildCtxt, error)

GetBuildContext returns a build context from go/build. When the $GOROOT variable is not set in the users environment it sets the context's root path to the path returned by 'go env GOROOT'.

Jump to

Keyboard shortcuts

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