(path string, _ graph.Options)
| 44 | } |
| 45 | |
| 46 | func Create(path string, _ graph.Options) (hkv.KV, error) { |
| 47 | err := os.MkdirAll(path, 0700) |
| 48 | if err != nil { |
| 49 | return nil, err |
| 50 | } |
| 51 | db, err := bolt.Open(getBoltFile(path), nil) |
| 52 | if err != nil { |
| 53 | clog.Errorf("Error: couldn't create Bolt database: %v", err) |
| 54 | return nil, err |
| 55 | } |
| 56 | return db, nil |
| 57 | } |
| 58 | |
| 59 | func Open(path string, opt graph.Options) (hkv.KV, error) { |
| 60 | db, err := bolt.Open(getBoltFile(path), nil) |