Skip to content

Navigation Menu

Sign in
Sign up

Latest commit

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

FileDB

FileDB is a simple file-based database written in Go. It provides basic CRUD operations on documents, which are stored as JSON files in a directory structure. The library also handles concurrent modifications and provides a simple key-based access to the documents.

Installation

To use FileDB in your Go project, you can install it by running:

go get github.com/oxplot/filedb

Usage

Here is a basic example of how to use FileDB:

package main
import (
	"fmt"
	"github.com/yourusername/filedb"
)
func main() {
	db, err := filedb.Open("/path/to/db")
	if err != nil {
		panic(err)
	}
	err = db.Set("key", "value")
	if err != nil {
		panic(err)
	}
	value, err := db.Get("key")
	if err != nil {
		panic(err)
	}
	fmt.Println(value) // Output: value
}

About

FileDB is a simple file-based database written in Go.

Resources

Stars

1 star

Watchers

1 watching

Forks

Used by

Contributors

Languages

AltStyle によって変換されたページ (->オリジナル) /