Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
An implementation of Douglas Crockfords Base32-Encoding in Ruby
branch: master

This branch is 16 commits behind levinalex:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib/base32
README.markdown
Rakefile
base32.gemspec

README.markdown

An implementation of Douglas Crockfords Base32-Encoding in Ruby

see http://www.crockford.com/wrmg/base32.html

Installation

$ gem sources -a http://gems.github.com
$ sudo gem install levinalex-base32

Changes

0.0.2 - ruby 1.9 compatibility
0.0.1 - initial release

Usage

#!/usr/bin/env ruby

require 'base32/crockford'

Base32::Crockford.encode(1234)                            # => "16J"
Base32::Crockford.encode(100**10, :split=>5, :length=>15) # => "02PQH-TY5NH-H0000"
Base32::Crockford.decode("2pqh-ty5nh-hoooo")              # => 10**100
Something went wrong with that request. Please try again.