diff --git a/util.go b/util.go index 5791c22..8037845 100644 --- a/util.go +++ b/util.go @@ -1,25 +1,9 @@ package clover import ( - "io/ioutil" "os" - "path/filepath" - "strings" ) -func listDir(dir string) ([]string, error) { - fInfos, err := ioutil.ReadDir(dir) - if err != nil { - return nil, err - } - - filenames := make([]string, 0, len(fInfos)) - for _, info := range fInfos { - filenames = append(filenames, info.Name()) - } - return filenames, nil -} - const defaultPermDir = 0777 func makeDirIfNotExists(dir string) error { @@ -29,11 +13,6 @@ func makeDirIfNotExists(dir string) error { return nil } -func getBasename(filename string) string { - baseName := filepath.Base(filename) - return strings.TrimSuffix(baseName, filepath.Ext(baseName)) -} - func copyMap(m map[string]interface{}) map[string]interface{} { mapCopy := make(map[string]interface{}) for k, v := range m {