util

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2018 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DirToGoPkg

func DirToGoPkg(dir string) (pkg string, err error)

DirToGoPkg returns the Gopkg for the given directory if it exists under a GOPATH otherwise returns error. For example, /Users/x/go/src/github.com/y/z ==> github.com/y/z

func GetDomainFromProject

func GetDomainFromProject(rootPath string) string

GetDomainFromProject get domain information from the PROJECT file under the path.

func IsGoSrcPath

func IsGoSrcPath(filePath string) bool

IsGoSrcPath validate if given path is of path $GOPATH/src.

func IsUnderGoSrcPath

func IsUnderGoSrcPath(filePath string) bool

IsUnderGoSrcPath validate if given path is under path $GOPATH/src.

func PathHasProjectFile

func PathHasProjectFile(filePath string) bool

PathHasProjectFile validate if PROJECT file exists under the path.

Types

This section is empty.

Jump to

Keyboard shortcuts

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