Documentation
¶
Index ¶
- Variables
- func AbsolutizePaths(files []string) ([]string, error)
- func AppendIfNotPresent(target []string, elements ...string) []string
- func EnsureFolderExists(folder string) error
- func Filter(slice []string, fn filterFunc) []string
- func FilterDirs(files []os.FileInfo) []os.FileInfo
- func FilterFiles() filterFiles
- func FilterFilesWithExtensions(extensions ...string) filterFiles
- func FilterOutFoldersByNames(folders []os.FileInfo, names ...string) []os.FileInfo
- func FindFilesInFolder(files *[]string, folder string, extensions CheckExtensionFunc, recurse bool) error
- func GetParentFolder(basefolder string, n int) string
- func IsHiddenFile(file os.FileInfo) bool
- func IsSCCSFile(file os.FileInfo) bool
- func IsSCCSOrHiddenFile(file os.FileInfo) bool
- func KeysOfMapOfString(input map[string]string) []string
- func KeysOfMapOfStringInterface(input map[string]interface{}) []string
- func LogIfVerbose(level string, format string, args ...interface{}) types.Command
- func LogThis(level string, format string, args ...interface{}) types.Command
- func MD5Sum(data []byte) string
- func Map(slice []string, fn mapFunc) []string
- func MapHas(aMap map[string]interface{}, key string) bool
- func MapStringStringHas(aMap map[string]string, key string) bool
- func NULLFile() string
- func ParseCommandLine(input string, logger i18n.Logger) ([]string, error)
- func ParseCppString(line string) (string, string, bool)
- func PrepareCommand(pattern string, logger i18n.Logger) (*exec.Cmd, error)
- func PrepareCommandFilteredArgs(pattern string, filter argFilterFunc, logger i18n.Logger) (*exec.Cmd, error)
- func PrettyOSName() string
- func QuoteCppString(str string) string
- func ReadDirFiltered(folder string, fn filterFiles) ([]os.FileInfo, error)
- func ReadFileToRows(file string) ([]string, error)
- func SliceContains(slice []string, target string) bool
- func SliceToMapStringBool(keys []string, value bool) map[string]bool
- func TheOnlySubfolderOf(folder string) (string, error)
- func TouchFile(targetFilePath string) error
- func TrimSpace(value string) string
- func WrapWithHyphenI(value string) string
- func WriteFile(targetFilePath string, data string) error
- func WriteFileBytes(targetFilePath string, data []byte) error
- type CheckExtensionFunc
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func AbsolutizePaths ¶
func AppendIfNotPresent ¶
func EnsureFolderExists ¶
func FilterFiles ¶
func FilterFiles() filterFiles
func FilterFilesWithExtensions ¶
func FilterFilesWithExtensions(extensions ...string) filterFiles
func FilterOutFoldersByNames ¶
func FindFilesInFolder ¶
func FindFilesInFolder(files *[]string, folder string, extensions CheckExtensionFunc, recurse bool) error
func GetParentFolder ¶
func IsHiddenFile ¶
func IsSCCSFile ¶
func IsSCCSOrHiddenFile ¶
func KeysOfMapOfString ¶
func LogIfVerbose ¶
func ParseCppString ¶
Parse a C-preprocessor string as emitted by the preprocessor. This is a string contained in double quotes, with any backslashes or quotes escaped with a backslash. If a valid string was present at the start of the given line, returns the unquoted string contents, the remaineder of the line (everything after the closing "), and true. Otherwise, returns the empty string, the entire line and false.
func PrettyOSName ¶
func PrettyOSName() string
func QuoteCppString ¶
Returns the given string as a quoted string for use with the C preprocessor. This adds double quotes around it and escapes any double quotes and backslashes in the string.
func ReadFileToRows ¶
func SliceContains ¶
func TheOnlySubfolderOf ¶
func WrapWithHyphenI ¶
func WriteFileBytes ¶
Types ¶
type CheckExtensionFunc ¶
Click to show internal directories.
Click to hide internal directories.