func NewBolt(dbpath *string) Storable {
	if _, err := os.Stat(*dbpath); os.IsNotExist(err) {
		os.Mkdir(*dbpath, os.ModeDir)
	}

	dbFile := filepath.Join(*dbpath, BoltDBFile)
	db, err := bolt.Open(dbFile, 0600, nil)
	if err != nil {
		logrus.Error("Unable to open filepath ", dbFile, err)
		return nil
	}

	return &boltStorage{
		client: db,
	}
}
// NewBolt initializes a new repository
NewBolt initializes a new repository
// NewBolt initializes a new repository
func NewBolt(dbpath *string) Storable {
	if _, err := os.Stat(*dbpath); os.IsNotExist(err) {
		os.Mkdir(*dbpath, os.ModeDir)
	}
	dbFile := filepath.Join(*dbpath, BoltDBFile)
	db, err := bolt.Open(dbFile, 0600, nil)
	if err != nil {
		logrus.Error("Unable to open filepath ", dbFile, err)
		return nil
	}
	return &boltStorage{
		client: db,
	}
}
func NewBolt ( dbpath * string ) Storable { if _ , err := os . Stat ( * dbpath ) ; os . IsNotExist ( err ) { os . Mkdir ( * dbpath , os . ModeDir ) } dbFile := filepath . Join ( * dbpath , BoltDBFile ) db , err := bolt . Open ( dbFile , 0600 , nil ) if err != nil { logrus . Error ( " " , dbFile , err ) return nil } return & boltStorage { client : db , } }
NewBolt initializes a new repository
NewBolt initializes a new repository