Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Ruby bindings for LevelDB
C++ Ruby C
branch: master

This branch is 46 commits behind wmorgan:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
ext/leveldb
leveldb
lib
test
.gitignore
README
RELEASE-SCRIPT
Rakefile
setup.rb

README

LevelDB Ruby bindings.

Do this:

  gem install leveldb-ruby


And then run this:

  require 'rubygems' # on ruby < 1.9
  require 'leveldb'

  db = LevelDB::DB.new "/tmp/asdf"
  db.put "it", "works"
  db.get "it"

Only a very few operations are supported right now:

  DB.new    # creates or loads as necessary
  DB.create # dies if it already exists
  DB.load   # dies unless it alread exists

  DB#get    # alias: DB#[]
  DB#put    # alias: DB#[]=
  DB#delete

  DB#each
  ... and all the enumerable methods
Something went wrong with that request. Please try again.