Documentation ¶
Index ¶
- Variables
- type Tpl
- func (tpl *Tpl) AddFileFuncMap(funcMap template.FuncMap)
- func (tpl *Tpl) CreateTpl(data any, autoMoveBasePath, zipFilePath string, replaceIfExist bool) (err error)
- func (tpl *Tpl) PreviewTpl(data any) (resultMap map[string]string, err error)
- func (tpl *Tpl) SetFileNamePlaceHolder(fileNamePlaceHolder string)
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrFileExist = errors.New("file exist")
Functions ¶
This section is empty.
Types ¶
type Tpl ¶
type Tpl struct { TplDir string TempDir string ReplaceFileName string // contains filtered or unexported fields }
func (*Tpl) AddFileFuncMap ¶
func (*Tpl) CreateTpl ¶
func (tpl *Tpl) CreateTpl(data any, autoMoveBasePath, zipFilePath string, replaceIfExist bool) (err error)
zipFilePath: path with file name e.x: "./code.zip"
func (*Tpl) PreviewTpl ¶
func (*Tpl) SetFileNamePlaceHolder ¶
Click to show internal directories.
Click to hide internal directories.