Documentation ¶
Index ¶
- func JoinPath(pieces []string) string
- func SplitPath(path string) ([]string, string)
- type BytesSource
- type File
- func (r *File) Bytes() ([]byte, error)
- func (r *File) Description() string
- func (r *File) IsForOutput() bool
- func (r *File) IsLibrary() bool
- func (r *File) IsTemplate() bool
- func (r *File) MarkForOutput(forOutput bool)
- func (r *File) MarkRelativePath(relPath string)
- func (r *File) MarkTemplate(template bool)
- func (r *File) MarkType(t Type)
- func (r *File) OriginalRelativePath() string
- func (r *File) RelativePath() string
- func (r *File) Type() Type
- type HTTPSource
- type LocalSource
- type OutputDirectory
- type OutputFile
- type Source
- type StdinSource
- type Type
- type UI
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BytesSource ¶
type BytesSource struct {
// contains filtered or unexported fields
}
func NewBytesSource ¶
func NewBytesSource(path string, data []byte) BytesSource
func (BytesSource) Bytes ¶
func (s BytesSource) Bytes() ([]byte, error)
func (BytesSource) Description ¶
func (s BytesSource) Description() string
func (BytesSource) RelativePath ¶
func (s BytesSource) RelativePath() (string, error)
type File ¶
type File struct {
// contains filtered or unexported fields
}
func MustNewFileFromSource ¶
func NewFileFromSource ¶
func (*File) Description ¶
func (*File) IsForOutput ¶ added in v0.4.0
func (*File) IsTemplate ¶
func (*File) MarkForOutput ¶ added in v0.4.0
func (*File) MarkRelativePath ¶ added in v0.4.0
func (*File) MarkTemplate ¶ added in v0.4.0
func (*File) OriginalRelativePath ¶ added in v0.4.0
func (*File) RelativePath ¶
type HTTPSource ¶
type HTTPSource struct {
// contains filtered or unexported fields
}
func NewHTTPSource ¶
func NewHTTPSource(path string) HTTPSource
func (HTTPSource) Bytes ¶
func (s HTTPSource) Bytes() ([]byte, error)
func (HTTPSource) Description ¶
func (s HTTPSource) Description() string
func (HTTPSource) RelativePath ¶
func (s HTTPSource) RelativePath() (string, error)
type LocalSource ¶
type LocalSource struct {
// contains filtered or unexported fields
}
func NewLocalSource ¶
func NewLocalSource(path, dir string) LocalSource
func NewRegularFileLocalSource ¶ added in v0.2.0
func NewRegularFileLocalSource(path, dir string, fi os.FileInfo) (LocalSource, error)
func (LocalSource) Bytes ¶
func (s LocalSource) Bytes() ([]byte, error)
func (LocalSource) Description ¶
func (s LocalSource) Description() string
func (LocalSource) RelativePath ¶
func (s LocalSource) RelativePath() (string, error)
type OutputDirectory ¶
type OutputDirectory struct {
// contains filtered or unexported fields
}
func NewOutputDirectory ¶
func NewOutputDirectory(path string, files []OutputFile, ui UI) *OutputDirectory
func (*OutputDirectory) Files ¶
func (d *OutputDirectory) Files() []OutputFile
func (*OutputDirectory) Write ¶
func (d *OutputDirectory) Write() error
type OutputFile ¶
type OutputFile struct {
// contains filtered or unexported fields
}
func NewOutputFile ¶
func NewOutputFile(relativePath string, data []byte) OutputFile
func (OutputFile) Bytes ¶
func (f OutputFile) Bytes() []byte
func (OutputFile) Create ¶
func (f OutputFile) Create(dirPath string) error
func (OutputFile) Path ¶
func (f OutputFile) Path(dirPath string) string
func (OutputFile) RelativePath ¶
func (f OutputFile) RelativePath() string
type StdinSource ¶
type StdinSource struct {
// contains filtered or unexported fields
}
func NewStdinSource ¶
func NewStdinSource() StdinSource
func (StdinSource) Bytes ¶
func (s StdinSource) Bytes() ([]byte, error)
func (StdinSource) Description ¶
func (s StdinSource) Description() string
func (StdinSource) RelativePath ¶
func (s StdinSource) RelativePath() (string, error)
Click to show internal directories.
Click to hide internal directories.