Skip to content
/ proquint Public

Ruby implementation of readable, spellable, pronounceable identifiers

License

Notifications You must be signed in to change notification settings

bjjb/proquint

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Proquint

A library for converting numbers to readable, pronounceable, spellable identifiers.

See http://arxiv.org/html/0901.4016.

Installation

Add this line to your application's Gemfile:

gem 'proquint'

And then execute:

$ bundle

Or install it yourself as:

$ gem install proquint

Usage

require 'proquint'
Proquint.encode(1)                  #=> "babad"
Proquint.encode(1234567890123456)   #=> "babah-karij-gufap-rorab"
Proquint.encode(0x462d53c8abac0)    #=> "babah-karij-gufap-rorab"
Proquint.encode(0x1234567890abcdef) #=> "damuh-jinum-nafor-suloz"
Proquint.decode("nobol-gonad")      #=> [38951, 14913]
Proquint.words2num([38951, 14913])  #=> 2552707649

Contributing

  1. Fork it ( https://github.com/[my-github-username]/proquint/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Build Status

About

Ruby implementation of readable, spellable, pronounceable identifiers

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages