Skip to content

Latest commit

 

History

History
31 lines (22 loc) · 497 Bytes

README.md

File metadata and controls

31 lines (22 loc) · 497 Bytes

rust-kennitala

Simple crate for handling Icelandic national identifiers

Works with rust 1.7 stable

Usage

Add this to your Cargo.toml

[dependencies.kennitala]
git = "https://github.com/Dagur/rust-kennitala.git"

And import and use like this

extern crate kennitala;
use kennitala::is_valid;

fn main(){
        if is_valid("012345-6789") {
                println!("Valid kennitala")
        } else {
                println!("Invalid")
        }
}