Documentation ¶
Index ¶
- Constants
- func CleanIncludePath()
- func ClearDir(dir string) error
- func Die(err error)
- func Dir(useLocal bool, name string) http.FileSystem
- func ExtractIncludes(path string) error
- func FS(useLocal bool) http.FileSystem
- func FSByte(useLocal bool, name string) ([]byte, error)
- func FSMustByte(useLocal bool, name string) []byte
- func FSMustString(useLocal bool, name string) string
- func FSString(useLocal bool, name string) (string, error)
- func GetDefaultProtoc(incPath string) (protoc string, newProtocIncPath string)
- func GetIncludePath(userPath string, filePath string) string
- func GetProtoapiHome() string
- func IsStrInSlice(str string, slice []string) bool
Constants ¶
const ( //ProtocBin path for protoc binary under protoapi home ProtocBin = "bin/protoc" //ProtoapiCommonInclude protoapi common proto file directory ProtoapiCommonInclude = "include/protoapi/" )
Variables ¶
This section is empty.
Functions ¶
func Dir ¶
func Dir(useLocal bool, name string) http.FileSystem
Dir returns a http.Filesystem for the embedded assets on a given prefix dir. If useLocal is true, the filesystem's contents are instead used.
func ExtractIncludes ¶
ExtractIncludes extract common protoconf includes
func FS ¶
func FS(useLocal bool) http.FileSystem
FS returns a http.Filesystem for the embedded assets. If useLocal is true, the filesystem's contents are instead used.
func FSByte ¶
FSByte returns the named file from the embedded assets. If useLocal is true, the filesystem's contents are instead used.
func FSMustByte ¶
FSMustByte is the same as FSByte, but panics if name is not present.
func FSMustString ¶
FSMustString is the string version of FSMustByte.
func GetDefaultProtoc ¶
GetDefaultProtoc retrieve protoc executable path and protoc Include path
func GetIncludePath ¶
GetIncludePath returns the actual include path
func IsStrInSlice ¶
Types ¶
This section is empty.