Documentation ¶
Index ¶
Constants ¶
View Source
const ( // Application describes project that results in executable Application = iota // Library is a project that other can depend on (include) Library = iota // HeaderOnly is a library that does not require linking HeaderOnly = iota // Unknown means project could not be identified Unknown = iota )
Variables ¶
View Source
var AppFs = afero.NewOsFs()
AppFs is a interface to the filesystem, used for mocking tests
Functions ¶
This section is empty.
Types ¶
type DefaultProject ¶
type DefaultProject struct{}
DefaultProject represents default assumptions gb makes while building projects. Gb entire idea is based on Convention-over-Configuration, and Gb infers as much as possible from project folder sturcture. Similar to Ruby or Java's Maven.
func (DefaultProject) Get ¶
func (DefaultProject) Get(projectRoot string, buildRoot string) (ProjectInfo, error)
type ProjectInfo ¶
type ProjectInfo struct { Type int8 Name string PublicIncludes string Sources []SourceFile Tests []SourceFile TestsIncludes []string HasTests bool HasPublicIncludes bool Path struct { Includes string Sources string Tests string } Dependencies []string }
ProjectInfo contains all information needed to build a project
type ProjectLayout ¶
type ProjectLayout interface {
Get(projectRoot string, buildRoot string) (ProjectInfo, error)
}
ProjectLayout provides set of functions for describing C++ project
func NewDefaultProjectLayout ¶
func NewDefaultProjectLayout() ProjectLayout
NewDefaultProjectLayout returns implementation of ProjectLayout for Gb default layout
type SourceFile ¶
SourceFile handles metainformation for file that can be compiled
func GetProjectFiles ¶
func GetProjectFiles(root string, globPattern string, buildRoot string) ([]SourceFile, error)
Click to show internal directories.
Click to hide internal directories.