romanianvalidators 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/README.md +33 -4
  2. data/romanianvalidators.gemspec +1 -1
  3. metadata +1 -1
data/README.md CHANGED
@@ -6,13 +6,42 @@ Rails validators for:
6
6
  * Cod de identificare fiscală (CIF) and
7
7
  * IBAN (only Romanian format as published by Romanian National Bank).
8
8
 
9
- # Installation
9
+ ## Installation
10
10
 
11
+ ### In a Rails 3 app, as a gem
11
12
 
12
- # TODO
13
+ First include it in your Gemfile.
13
14
 
14
- * test more edge cases; test nil, blank; test messages
15
+ $ cat Gemfile
16
+ ...
17
+ gem 'romanianvalidations'
18
+ ...
15
19
 
16
- ## Copyright
20
+ Next install it with Bundler.
21
+
22
+ $ bundle install
23
+
24
+ ## Usage
25
+
26
+ In your models (ActiveModel), the gem provides the following new validators:
27
+ * CIF
28
+ * CNP
29
+ * IBAN
30
+ * BIC
31
+
32
+ The algorithms for validation are found in the source code.
33
+
34
+ ```ruby
35
+ class User
36
+ validates :cnp, :cnp => true
37
+ validates :company_cif, :cif => true
38
+ end
39
+ ```
40
+
41
+ ### TODO
42
+
43
+ * test more edge cases; test nil, blank; test messages; test in app
44
+
45
+ ### Copyright
17
46
 
18
47
  Copyright (c) 2007-2012 Mihai Târnovan. MIT LICENSE. See LICENSE for details.
@@ -1,7 +1,7 @@
1
1
  # -*- encoding: utf-8 -*-
2
2
  Gem::Specification.new do |s|
3
3
  s.name = 'romanianvalidators'
4
- s.version = '0.1.0'
4
+ s.version = '0.1.1'
5
5
  s.authors = ['Mihai Târnovan']
6
6
  s.email = ['mihai.tarnovan@cubus.ro']
7
7
  s.homepage = 'http://github.com/mtarnovan/romanianvalidators'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: romanianvalidators
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: