Documentation
¶
Index ¶
Constants ¶
View Source
const ( Node = "node" NodeModules = "node_modules" Yarn = "yarn" )
View Source
const NoStartScriptError = "no start script in package.json"
NoStartScriptError indicates that the targeted project does no have a start command in their package.json
Variables ¶
This section is empty.
Functions ¶
func Build ¶
func Build(pathParser PathParser, logger scribe.Emitter) packit.BuildFunc
func Detect ¶
func Detect(projectPathParser PathParser) packit.DetectFunc
Types ¶
type PackageJson ¶ added in v0.8.0
type PackageJson struct {
Scripts PackageScripts `json:"scripts"`
}
func NewPackageJsonFromPath ¶ added in v0.8.0
func NewPackageJsonFromPath(filelocation string) (*PackageJson, error)
type PackageScripts ¶ added in v0.8.0
type PathParser ¶ added in v0.0.5
type ProjectPathParser ¶ added in v0.0.5
type ProjectPathParser struct{}
ProjectPathParser provides a mechanism for determining the proper working directory for the build process.
func NewProjectPathParser ¶ added in v0.0.5
func NewProjectPathParser() ProjectPathParser
NewProjectPathParser creates an instance of a ProjectPathParser.
func (ProjectPathParser) Get ¶ added in v0.0.5
func (p ProjectPathParser) Get(path string) (string, error)
Get will resolve the absolute path of the directory specified by the $BP_NODE_PROJECT_PATH environment variable. It assumes that $BP_NODE_PROJECT_PATH is relative to the provided path argument.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.