util

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CloneProjectFromRemote

func CloneProjectFromRemote(dir, remote string) error

CloneProjectFromRemote clone project from remote

func CreateIfNotExist

func CreateIfNotExist(file string) (*os.File, error)

CreateIfNotExist creates a file if it is not exists

func GetCurrentPath

func GetCurrentPath() (string, error)

GetCurrentPath get current folder path

func GetGoModulePath

func GetGoModulePath() (string, error)

GetGoModulePath get go module path from local

func GetGoPath

func GetGoPath() (string, error)

GetGoPath get go path from env

func GetProjectPath

func GetProjectPath(name string) (string, error)

GetProjectPath get project path

func GetValueFromInput

func GetValueFromInput(label string) (string, error)

GetValueFromInput get value from input

func GetValueFromMultiSelect

func GetValueFromMultiSelect(label string, options []string) ([]string, error)

GetValueFromMultiSelect get value from multi select

func GetValueFromSelect

func GetValueFromSelect(label string, options []string) (string, error)

GetValueFromSelect get value from select

func IsFileExist

func IsFileExist(file string) bool

IsFileExist returns true if the specified file is exists

func IsFolderExist

func IsFolderExist(dir string) bool

IsFolderExist determine if a folder already exists

func MkdirIfNotExist

func MkdirIfNotExist(dir string) error

MkdirIfNotExist makes directories if the input path is not exists

func RemoveIfExist

func RemoveIfExist(filename string) error

RemoveIfExist deletes the specified file if it is exists

Types

This section is empty.

Jump to

Keyboard shortcuts

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