gleborator 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.DS_Store +0 -0
- data/Gemfile +2 -0
- data/lib/.DS_Store +0 -0
- data/lib/gleborator/{BaseDecorator.rb → base_decorator.rb} +1 -1
- data/lib/gleborator/railtie.rb +13 -0
- data/lib/gleborator/setup.rb +12 -0
- data/lib/gleborator/version.rb +1 -1
- data/lib/gleborator.rb +8 -0
- metadata +6 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a08a5b230f4d6beaba24e094732d224cc93e02d5
|
4
|
+
data.tar.gz: 20029418b869c80f676784885b494d16b314abaf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 886081689145f21379a3f13f6c445288d3bb8c455dd27a7e80d01806db0dd7e7bc1d7edf2c1d991b85702d6296829847a88ae54e24c78b2ee1559bb7f6d45375
|
7
|
+
data.tar.gz: e2b7341d60f2f5b0835dc38d5c0fed7f740c808e7fbca3ce396891b5d18a6300b99b9f95595f3702c27ef6d9cc7e80d4eeb37cece9ffe702735cf3e397f5ea97
|
data/.DS_Store
ADDED
Binary file
|
data/Gemfile
CHANGED
data/lib/.DS_Store
ADDED
Binary file
|
@@ -0,0 +1,12 @@
|
|
1
|
+
module Gleborator
|
2
|
+
module Setup
|
3
|
+
def decorate
|
4
|
+
begin
|
5
|
+
decorator_class = "#{self.class.name}Decorator".constantize
|
6
|
+
decorator_class.wrap(self)
|
7
|
+
rescue NameError => e
|
8
|
+
raise "Couldn't find decorator #{self.class.name}Decorator"
|
9
|
+
end
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
data/lib/gleborator/version.rb
CHANGED
data/lib/gleborator.rb
CHANGED
@@ -1,4 +1,12 @@
|
|
1
1
|
require "gleborator/version"
|
2
|
+
require "gleborator/base_decorator"
|
3
|
+
require "gleborator/setup"
|
4
|
+
require "gleborator/railtie" if defined?(Rails)
|
2
5
|
|
3
6
|
module Gleborator
|
7
|
+
def self.setup(klass)
|
8
|
+
klass.class_eval do
|
9
|
+
include Gleborator::Setup
|
10
|
+
end
|
11
|
+
end
|
4
12
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gleborator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gleb Vishnevsky
|
@@ -59,6 +59,7 @@ executables: []
|
|
59
59
|
extensions: []
|
60
60
|
extra_rdoc_files: []
|
61
61
|
files:
|
62
|
+
- ".DS_Store"
|
62
63
|
- ".gitignore"
|
63
64
|
- ".rspec"
|
64
65
|
- ".travis.yml"
|
@@ -69,8 +70,11 @@ files:
|
|
69
70
|
- bin/console
|
70
71
|
- bin/setup
|
71
72
|
- gleborator.gemspec
|
73
|
+
- lib/.DS_Store
|
72
74
|
- lib/gleborator.rb
|
73
|
-
- lib/gleborator/
|
75
|
+
- lib/gleborator/base_decorator.rb
|
76
|
+
- lib/gleborator/railtie.rb
|
77
|
+
- lib/gleborator/setup.rb
|
74
78
|
- lib/gleborator/version.rb
|
75
79
|
homepage: https://github.com/kaikash/gleborator
|
76
80
|
licenses:
|