BSD Ports

textproc/ruby-levenshtein 0.2.2 NetBSD

Calculates the Levenshtein distance between two byte strings

System
NetBSD
Repository
pkgsrc
Maintainer
[email protected]
License
gnu-gpl-v2
Categories
textproc, ruby
Package size
19.3 KiB, 58.1 KiB installed

Description

The Levenshtein distance is a metric for measuring the amount of difference between two sequences (i.e., the so called edit distance). The Levenshtein distance between two sequences is given by the minimum number of operations needed to transform one sequence into the other, where an operation is an insertion, deletion, or substitution of a single element.

The two sequences can be two strings, two arrays, or two other objects responding to :each. All sequences are by generic (fast) C code.

All objects in the sequences should respond to :hash and :eql?.

More information about the Levenshtein distance algorithm: http://en.wikipedia.org/wiki/Levenshtein_distance .

Install

Binary package:

pkgin install ruby33-levenshtein

From pkgsrc:

cd /usr/pkgsrc/textproc/ruby-levenshtein && make install clean

Dependencies

Run dependencies 1

No port depends on this one.

Configuration

No options to configure.

Service scripts
none
Flavors
ruby34-levenshtein-0.2.2, ruby40-levenshtein-0.2.2