1
0
Fork 0
mirror of https://github.com/vbatts/dedupe-linker.git synced 2025-07-29 13:30:30 +00:00
This commit is contained in:
Vincent Batts 2014-09-12 16:10:10 -04:00
parent 0a054d3410
commit 842fa03b61
4 changed files with 220 additions and 177 deletions

24
base/base.go Normal file
View file

@ -0,0 +1,24 @@
package base
import (
"crypto"
"os"
"path/filepath"
)
func InitVarBase(base string) error {
for _, path := range []string{"dedup/blobs", "dedup/state"} {
if err := os.MkdirAll(filepath.Join(base, path), 0755); err != nil {
return err
}
}
return nil
}
type Base struct {
Path string
}
func (b Base) HasBlob(hashType crypto.Hash, sum string) bool {
return true
}