aboutsummaryrefslogtreecommitdiffstats
path: root/storage/filesystem/storage.go
diff options
context:
space:
mode:
authorMáximo Cuadros <mcuadros@gmail.com>2017-05-21 19:28:05 +0200
committerMáximo Cuadros <mcuadros@gmail.com>2017-05-21 19:28:05 +0200
commit8fbb9914931704257581f5a7474ee3f2abc3780f (patch)
treeaa27da9eb77c76b9d9912bb94d92c59823446692 /storage/filesystem/storage.go
parentd98ebb5e42cd07007010f6d10db11a792c58206e (diff)
downloadgo-git-8fbb9914931704257581f5a7474ee3f2abc3780f.tar.gz
storage: filesystem, initialize the default folder scaffolding
Diffstat (limited to 'storage/filesystem/storage.go')
-rw-r--r--storage/filesystem/storage.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/storage/filesystem/storage.go b/storage/filesystem/storage.go
index 6d58006..dcb061d 100644
--- a/storage/filesystem/storage.go
+++ b/storage/filesystem/storage.go
@@ -24,6 +24,10 @@ type Storage struct {
// NewStorage returns a new Storage backed by a given `fs.Filesystem`
func NewStorage(fs billy.Filesystem) (*Storage, error) {
dir := dotgit.New(fs)
+ if err := dir.Initialize(); err != nil {
+ return nil, err
+ }
+
o, err := newObjectStorage(dir)
if err != nil {
return nil, err