dsl 0.2.2 → 0.2.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. data/Gemfile.lock +1 -1
  2. data/README.md +9 -2
  3. data/Rakefile +1 -1
  4. data/VERSION +1 -1
  5. metadata +4 -4
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- dsl (0.2.2)
4
+ dsl (0.2.3)
5
5
  version (~> 1.0.0)
6
6
 
7
7
  GEM
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # DSL
1
+ # DSL [![Build Status](https://secure.travis-ci.org/c00lryguy/dsl.png)](http://travis-ci.org/c00lryguy/dsl)
2
2
 
3
3
  ## Description
4
4
 
@@ -16,7 +16,6 @@ Helpers for the creation of Domain Specific Languages within your libraries and
16
16
 
17
17
  ## Usage
18
18
 
19
-
20
19
  ### Simple
21
20
 
22
21
  ```ruby
@@ -42,13 +41,21 @@ end
42
41
 
43
42
  char = Character.new do
44
43
  name 'john doe'
44
+ p name # => "JOHN"
45
45
  age '21'
46
+ p age # => 21
46
47
  end
47
48
 
48
49
  char.name # => "JOHN"
49
50
  char.age # => 21
50
51
  ```
51
52
 
53
+ `def_dsl_delegator` defines a method that accepts a variable number of arguments that will delegate to the parent.
54
+ This will attempt to call the setter/getter method before attempting to access the instance variable directly.
55
+
56
+ This way, any modifications you do to the instance variables in those methods will be used. Try adding a custom
57
+ getter to the example above and you will get the expected outcome.
58
+
52
59
  ## License
53
60
 
54
61
  Copyright (c) 2010-2012 Ryan Lewis. See LICENSE for details.
data/Rakefile CHANGED
@@ -15,7 +15,7 @@ spec = Gem::Specification.new do |s|
15
15
  s.files = `git ls-files`.lines.to_a.collect { |s| s.strip }
16
16
  s.executables = `git ls-files -- bin/*`.lines.to_a.collect { |s| File.basename(s.strip) }
17
17
 
18
- s.post_install_message = "NOTICE!\n\n DSL 0.2.x is INCOMPATIBLE with DSL 0.2.x!\n\n"
18
+ s.post_install_message = "NOTICE!\n\n DSL 0.2.x is INCOMPATIBLE with DSL 0.1.x!\n\n"
19
19
 
20
20
  s.add_dependency 'version', '~> 1.0.0'
21
21
  s.add_development_dependency 'rake', '~> 0.9'
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.2
1
+ 0.2.3
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dsl
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
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: 2012-11-04 00:00:00.000000000 Z
12
+ date: 2012-11-05 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: version
@@ -115,7 +115,7 @@ files:
115
115
  - spec/support/character_without_attributes.rb
116
116
  homepage: http://github.com/c00lryguy/dsl
117
117
  licenses: []
118
- post_install_message: ! "NOTICE!\n\n DSL 0.2.x is INCOMPATIBLE with DSL 0.2.x!\n\n"
118
+ post_install_message: ! "NOTICE!\n\n DSL 0.2.x is INCOMPATIBLE with DSL 0.1.x!\n\n"
119
119
  rdoc_options: []
120
120
  require_paths:
121
121
  - lib
@@ -127,7 +127,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
127
127
  version: '0'
128
128
  segments:
129
129
  - 0
130
- hash: 4402419048720528263
130
+ hash: -2054631078489085913
131
131
  required_rubygems_version: !ruby/object:Gem::Requirement
132
132
  none: false
133
133
  requirements: