From 4ba560f44343d34e638a11b6f9609f9ae3e5efe0 Mon Sep 17 00:00:00 2001 From: "Diogo Franco (Kovensky)" Date: Tue, 16 Jul 2013 19:53:13 -0300 Subject: [PATCH] Export Stringify --- cachekey.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cachekey.go b/cachekey.go index 37f88b9..8d8725d 100755 --- a/cachekey.go +++ b/cachekey.go @@ -26,7 +26,7 @@ type CacheKey interface{} // It's a superset of the "bad characters" on other OSes, so this works. var badPath = regexp.MustCompile(`[\\/:\*\?\"<>\|]`) -func stringify(stuff ...CacheKey) []string { +func Stringify(stuff ...CacheKey) []string { ret := make([]string, len(stuff)) for i := range stuff { s := fmt.Sprint(stuff[i]) @@ -41,7 +41,7 @@ func stringify(stuff ...CacheKey) []string { // This also means that cache keys that are file-backed // cannot have subkeys. func (cd *CacheDir) cachePath(key ...CacheKey) string { - parts := append([]string{cd.GetCacheDir()}, stringify(key...)...) + parts := append([]string{cd.GetCacheDir()}, Stringify(key...)...) p := filepath.Join(filterDots(parts...)...) return p } -- 2.44.0