gritano-core 1.1.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/gritano-core.gemspec +2 -2
- data/lib/gritano-core.rb +6 -6
- data/lib/gritano-core/key.rb +2 -2
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.1.
|
1
|
+
1.1.1
|
data/gritano-core.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "gritano-core"
|
8
|
-
s.version = "1.1.
|
8
|
+
s.version = "1.1.1"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Igor Bonadio"]
|
12
|
-
s.date = "2013-06-
|
12
|
+
s.date = "2013-06-13"
|
13
13
|
s.description = "Gritano::Core is a library that defines all Gritano's Models. It can be used to develop tools that manage users, repositories and permissions."
|
14
14
|
s.email = "igorbonadio@gmail.com"
|
15
15
|
s.extra_rdoc_files = [
|
data/lib/gritano-core.rb
CHANGED
@@ -1,10 +1,10 @@
|
|
1
|
-
|
1
|
+
root_path = File.expand_path(File.dirname(__FILE__))
|
2
2
|
|
3
3
|
require 'active_record'
|
4
4
|
require 'grit'
|
5
5
|
|
6
|
-
require File.join(
|
7
|
-
require File.join(
|
8
|
-
require File.join(
|
9
|
-
require File.join(
|
10
|
-
require File.join(
|
6
|
+
require File.join(root_path, 'gritano-core/user')
|
7
|
+
require File.join(root_path, 'gritano-core/repository')
|
8
|
+
require File.join(root_path, 'gritano-core/permission')
|
9
|
+
require File.join(root_path, 'gritano-core/key')
|
10
|
+
require File.join(root_path, 'gritano-core/migration')
|
data/lib/gritano-core/key.rb
CHANGED
@@ -5,11 +5,11 @@ module Gritano
|
|
5
5
|
validates :name, uniqueness: {scope: :user_id}
|
6
6
|
|
7
7
|
validates :key, presence: true
|
8
|
-
validates :key, format: /\Assh-(?:dss|rsa)
|
8
|
+
validates :key, format: /\Assh-(?:dss|rsa) .*/
|
9
9
|
validates :user_id, presence: true
|
10
10
|
|
11
11
|
def key=(pubkey)
|
12
|
-
write_attribute(:key, pubkey.scan(/\Assh-(?:dss|rsa)
|
12
|
+
write_attribute(:key, pubkey.scan(/\Assh-(?:dss|rsa) .*/)[0][0..-2])
|
13
13
|
end
|
14
14
|
end
|
15
15
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gritano-core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2013-06-
|
12
|
+
date: 2013-06-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activerecord
|
@@ -210,7 +210,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
210
210
|
version: '0'
|
211
211
|
segments:
|
212
212
|
- 0
|
213
|
-
hash:
|
213
|
+
hash: -1111285386655195175
|
214
214
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
215
215
|
none: false
|
216
216
|
requirements:
|