this works great and support long file names

This commit is contained in:
Chris Lu
2018-05-26 14:08:55 -07:00
parent 2da84ed331
commit 955eae3500
3 changed files with 30 additions and 10 deletions

View File

@@ -0,0 +1,13 @@
package abstract_sql
import (
"crypto/md5"
"io"
)
// returns a 128 bit hash
func md5hash(dir string) []byte {
h := md5.New()
io.WriteString(h, dir)
return h.Sum(nil)
}