utils

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 27, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyFile

func CopyFile(sourcePath, destinationPath string) error

func DeferTeaPanicHandler added in v0.2.0

func DeferTeaPanicHandler(p *tea.Program)

func DoesDirectoryExistAndIsNotEmpty

func DoesDirectoryExistAndIsNotEmpty(name string) bool

func DoesDirectoryOrFileExist added in v0.3.0

func DoesDirectoryOrFileExist(path string) bool

func DownloadFile

func DownloadFile(url string, filepath string) error

func ExecuteCmd added in v0.2.0

func ExecuteCmd(name string, args []string, dir string) error

ExecuteCmd provides a shorthand way to run a shell command

func ExecuteTemplate added in v0.3.0

func ExecuteTemplate(t *template.Template, data interface{}) ([]byte, error)

func GetLastPathName added in v0.3.0

func GetLastPathName(path string) string

func GetLowercaseFirstChar added in v0.3.0

func GetLowercaseFirstChar(s string) string

func GetRefiberTemplateDirPath added in v0.3.0

func GetRefiberTemplateDirPath(currentWorkingDir *string) (*string, error)

func ListFolders added in v0.3.0

func ListFolders(dirPath string) (*[]*string, error)

func MatchAllStringByRegex

func MatchAllStringByRegex(regex, str string) ([]*string, error)

func WriteFile added in v0.3.0

func WriteFile(filename, path string, content []byte) error

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL