yard-value 1.2.2 → 1.2.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ff5e5cc3611bfd389ce635834c0ed77fd047935a
4
+ data.tar.gz: 585231da575f4f426e660b3431a31459a827e0be
5
+ SHA512:
6
+ metadata.gz: b0f79fbddf992ff1f4b6c6b64942054018c41156fca9af20aa167957cfc1e945c71fc0867811d14419133ede4ee9007f5744807b128192d2e101c7291de6abfe
7
+ data.tar.gz: dc87668977831c0033fba5798ddad12d2542ce75587fb12d68936343aed00f37cb33b1f8ee1f30079b3bc90885af950fc170f33895b4f2e05664abd31d8eab3b
data/README CHANGED
@@ -1,5 +1,112 @@
1
1
  YARD-Value
2
2
 
3
- YARD-Value provides YARD handlers for Value¹ objects.
3
+ YARD-Value provides YARD¹ handlers for Value² objects. It’ll document
4
+ whether the Value is Comparable and what attributes are used in such
5
+ comparisons, its #initialize method, and its protected accessors.
4
6
 
5
- ¹ Check out the Value library at http://disu.se/software/value
7
+ ¹ See http://yardoc.org/
8
+ ² See http://disu.se/software/value/
9
+
10
+ You add the documentation to the Module#Value invocation. Any ‹@param› tags
11
+ are used both for the parameters to the #initialize method and for the
12
+ protected accessors.
13
+
14
+ This
15
+
16
+ class Point
17
+ # A point on a plane.
18
+ # @param [Integer] x
19
+ # @param [Integer] y
20
+ Value :x, :y
21
+ end
22
+
23
+ generates documentation similar to
24
+
25
+ class Point
26
+ # A point on a plane.
27
+ # @param [Integer] x
28
+ # @param [Integer] y
29
+ def initialize(x, y)
30
+ end
31
+
32
+ and this
33
+
34
+ class Point
35
+ # A point on a plane.
36
+ # @param [Integer] x The x coordinate of the receiver
37
+ # @param [Integer] y The y coordinate of the receiver
38
+ Value :x, :y
39
+ end
40
+
41
+ generates documentation similar to
42
+
43
+ class Point
44
+ # A point on a plane.
45
+ # @param [Integer] x
46
+ # @param [Integer] y
47
+ def initialize(x, y)
48
+
49
+ protected
50
+
51
+ # @return [Integer] The x coordinate of the receiver
52
+ attr_reader :x
53
+
54
+ # @return [Integer] The y coordinate of the receiver
55
+ attr_reader :y
56
+ end
57
+
58
+ For comparable Values, a note is added about what attributes are used in the
59
+ comparison. This
60
+
61
+ class Point
62
+ # A point on a plane.
63
+ # @param [Integer] x
64
+ # @param [Integer] y
65
+ Value :x, :y, :comparable => true
66
+ end
67
+
68
+ is similar to
69
+
70
+ class Point
71
+ # A point on a plane.
72
+ # @param [Integer] x
73
+ # @param [Integer] y
74
+ # @note Comparisons between instances are made between x and y.
75
+ def initialize(x, y)
76
+ end
77
+
78
+ § Usage
79
+
80
+ Add ‹--plugin yard-value-1.0› to your YARD command line. If you’re
81
+ using Inventory-Rake-Tasks-YARD¹, add the following to your Rakefile:
82
+
83
+ Inventory::Rake::Tasks::YARD.new do |t|
84
+ t.options += %w'--plugin yard-value-1.0'
85
+ end
86
+
87
+ ¹ See http://disu.se/software/inventory-rake-tasks-yard/
88
+
89
+ § Financing
90
+
91
+ Currently, most of my time is spent at my day job and in my rather busy
92
+ private life. Please motivate me to spend time on this piece of software
93
+ by donating some of your money to this project. Yeah, I realize that
94
+ requesting money to develop software is a bit, well, capitalistic of me.
95
+ But please realize that I live in a capitalistic society and I need money
96
+ to have other people give me the things that I need to continue living
97
+ under the rules of said society. So, if you feel that this piece of
98
+ software has helped you out enough to warrant a reward, please PayPal a
99
+ donation to now@disu.se¹. Thanks! Your support won’t go unnoticed!
100
+
101
+ ¹ Send a donation:
102
+ https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=now%40disu%2ese&item_name=Nikolai%20Weibull%20Software%20Services
103
+
104
+ § Reporting Bugs
105
+
106
+ Please report any bugs that you encounter to the {issue tracker}¹.
107
+
108
+ ¹ See https://github.com/now/yard-value/issues
109
+
110
+ § Authors
111
+
112
+ Nikolai Weibull wrote the code, the tests, and this README.
data/Rakefile CHANGED
@@ -1,8 +1,8 @@
1
1
  # -*- coding: utf-8 -*-
2
2
 
3
- require 'inventory/rake-1.0'
3
+ require 'inventory-rake-1.0'
4
4
 
5
- load File.expand_path('../lib/yard-value/version.rb', __FILE__)
5
+ load File.expand_path('../lib/yard-value-1.0/version.rb', __FILE__)
6
6
 
7
7
  Inventory::Rake::Tasks.define YARDValue::Version, :gem => proc{ |_, s|
8
8
  s.author = 'Nikolai Weibull'
@@ -11,7 +11,7 @@ Inventory::Rake::Tasks.define YARDValue::Version, :gem => proc{ |_, s|
11
11
  }
12
12
 
13
13
  Inventory::Rake::Tasks.unless_installing_dependencies do
14
- require 'lookout/rake-3.0'
14
+ require 'lookout-rake-3.0'
15
15
  # TODO: Silence warnings generated from YARD (remove this once we plug them)
16
16
  Lookout::Rake::Tasks::Test.new :options => []
17
17
  end
@@ -2,7 +2,7 @@
2
2
 
3
3
  # Namespace for YARD extensions for Value.
4
4
  module YARDValue
5
- load File.expand_path('../yard-value/version.rb', __FILE__)
5
+ load File.expand_path('../yard-value-1.0/version.rb', __FILE__)
6
6
  Version.load
7
7
  end
8
8
 
@@ -46,7 +46,7 @@ class YARD::Handlers::Ruby::ValuesHandler < YARD::Handlers::Ruby::Base
46
46
  def define(name, parameters, docstring = nil, visibility = :public)
47
47
  YARD::CodeObjects::MethodObject.new(namespace, name).tap{ |m|
48
48
  register m
49
- register_docstring m, docstring, nil if docstring
49
+ register_docstring m, docstring if docstring
50
50
  m.signature = 'def %s%s' %
51
51
  [name,
52
52
  parameters.empty? ?
@@ -3,10 +3,10 @@
3
3
  require 'inventory-1.0'
4
4
 
5
5
  module YARDValue
6
- Version = Inventory.new(1, 2, 2){
6
+ Version = Inventory.new(1, 2, 3){
7
7
  def dependencies
8
8
  super + Inventory::Dependencies.new{
9
- development 'inventory-rake', 1, 3, 0
9
+ development 'inventory-rake', 1, 4, 0
10
10
  development 'lookout', 3, 0, 0
11
11
  development 'lookout-rake', 3, 0, 0
12
12
  runtime 'yard', 0, 8, 0, :feature => 'yard'
metadata CHANGED
@@ -1,82 +1,207 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: yard-value
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.2
5
- prerelease:
4
+ version: 1.2.3
6
5
  platform: ruby
7
6
  authors:
8
7
  - Nikolai Weibull
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2012-05-04 00:00:00.000000000 Z
11
+ date: 2013-04-30 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: inventory
16
- requirement: &15273456 !ruby/object:Gem::Requirement
17
- none: false
15
+ requirement: !ruby/object:Gem::Requirement
18
16
  requirements:
19
17
  - - ~>
20
18
  - !ruby/object:Gem::Version
21
- version: '1.3'
19
+ version: '1.4'
22
20
  type: :runtime
23
21
  prerelease: false
24
- version_requirements: *15273456
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ~>
25
+ - !ruby/object:Gem::Version
26
+ version: '1.4'
25
27
  - !ruby/object:Gem::Dependency
26
28
  name: inventory-rake
27
- requirement: &15289392 !ruby/object:Gem::Requirement
28
- none: false
29
+ requirement: !ruby/object:Gem::Requirement
29
30
  requirements:
30
31
  - - ~>
31
32
  - !ruby/object:Gem::Version
32
- version: '1.3'
33
+ version: '1.4'
33
34
  type: :development
34
35
  prerelease: false
35
- version_requirements: *15289392
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ~>
39
+ - !ruby/object:Gem::Version
40
+ version: '1.4'
36
41
  - !ruby/object:Gem::Dependency
37
42
  name: lookout
38
- requirement: &15288876 !ruby/object:Gem::Requirement
39
- none: false
43
+ requirement: !ruby/object:Gem::Requirement
40
44
  requirements:
41
45
  - - ~>
42
46
  - !ruby/object:Gem::Version
43
47
  version: '3.0'
44
48
  type: :development
45
49
  prerelease: false
46
- version_requirements: *15288876
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ~>
53
+ - !ruby/object:Gem::Version
54
+ version: '3.0'
47
55
  - !ruby/object:Gem::Dependency
48
56
  name: lookout-rake
49
- requirement: &15288480 !ruby/object:Gem::Requirement
50
- none: false
57
+ requirement: !ruby/object:Gem::Requirement
51
58
  requirements:
52
59
  - - ~>
53
60
  - !ruby/object:Gem::Version
54
61
  version: '3.0'
55
62
  type: :development
56
63
  prerelease: false
57
- version_requirements: *15288480
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ~>
67
+ - !ruby/object:Gem::Version
68
+ version: '3.0'
58
69
  - !ruby/object:Gem::Dependency
59
70
  name: yard
60
- requirement: &15287940 !ruby/object:Gem::Requirement
61
- none: false
71
+ requirement: !ruby/object:Gem::Requirement
62
72
  requirements:
63
73
  - - ~>
64
74
  - !ruby/object:Gem::Version
65
75
  version: 0.8.0
66
76
  type: :runtime
67
77
  prerelease: false
68
- version_requirements: *15287940
69
- description: ! " YARD-Value\n\n YARD-Value provides
70
- YARD handlers for Value¹ objects.\n\n¹ Check out the Value library at http://disu.se/software/value\n"
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ~>
81
+ - !ruby/object:Gem::Version
82
+ version: 0.8.0
83
+ description: |2
84
+ YARD-Value
85
+
86
+ YARD-Value provides YARD¹ handlers for Value² objects. It’ll document
87
+ whether the Value is Comparable and what attributes are used in such
88
+ comparisons, its #initialize method, and its protected accessors.
89
+
90
+ ¹ See http://yardoc.org/
91
+ ² See http://disu.se/software/value/
92
+
93
+ You add the documentation to the Module#Value invocation. Any ‹@param› tags
94
+ are used both for the parameters to the #initialize method and for the
95
+ protected accessors.
96
+
97
+ This
98
+
99
+ class Point
100
+ # A point on a plane.
101
+ # @param [Integer] x
102
+ # @param [Integer] y
103
+ Value :x, :y
104
+ end
105
+
106
+ generates documentation similar to
107
+
108
+ class Point
109
+ # A point on a plane.
110
+ # @param [Integer] x
111
+ # @param [Integer] y
112
+ def initialize(x, y)
113
+ end
114
+
115
+ and this
116
+
117
+ class Point
118
+ # A point on a plane.
119
+ # @param [Integer] x The x coordinate of the receiver
120
+ # @param [Integer] y The y coordinate of the receiver
121
+ Value :x, :y
122
+ end
123
+
124
+ generates documentation similar to
125
+
126
+ class Point
127
+ # A point on a plane.
128
+ # @param [Integer] x
129
+ # @param [Integer] y
130
+ def initialize(x, y)
131
+
132
+ protected
133
+
134
+ # @return [Integer] The x coordinate of the receiver
135
+ attr_reader :x
136
+
137
+ # @return [Integer] The y coordinate of the receiver
138
+ attr_reader :y
139
+ end
140
+
141
+ For comparable Values, a note is added about what attributes are used in the
142
+ comparison. This
143
+
144
+ class Point
145
+ # A point on a plane.
146
+ # @param [Integer] x
147
+ # @param [Integer] y
148
+ Value :x, :y, :comparable => true
149
+ end
150
+
151
+ is similar to
152
+
153
+ class Point
154
+ # A point on a plane.
155
+ # @param [Integer] x
156
+ # @param [Integer] y
157
+ # @note Comparisons between instances are made between x and y.
158
+ def initialize(x, y)
159
+ end
160
+
161
+ § Usage
162
+
163
+ Add ‹--plugin yard-value-1.0› to your YARD command line. If you’re
164
+ using Inventory-Rake-Tasks-YARD¹, add the following to your Rakefile:
165
+
166
+ Inventory::Rake::Tasks::YARD.new do |t|
167
+ t.options += %w'--plugin yard-value-1.0'
168
+ end
169
+
170
+ ¹ See http://disu.se/software/inventory-rake-tasks-yard/
171
+
172
+ § Financing
173
+
174
+ Currently, most of my time is spent at my day job and in my rather busy
175
+ private life. Please motivate me to spend time on this piece of software
176
+ by donating some of your money to this project. Yeah, I realize that
177
+ requesting money to develop software is a bit, well, capitalistic of me.
178
+ But please realize that I live in a capitalistic society and I need money
179
+ to have other people give me the things that I need to continue living
180
+ under the rules of said society. So, if you feel that this piece of
181
+ software has helped you out enough to warrant a reward, please PayPal a
182
+ donation to now@disu.se¹. Thanks! Your support won’t go unnoticed!
183
+
184
+ ¹ Send a donation:
185
+ https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=now%40disu%2ese&item_name=Nikolai%20Weibull%20Software%20Services
186
+
187
+ § Reporting Bugs
188
+
189
+ Please report any bugs that you encounter to the {issue tracker}¹.
190
+
191
+ ¹ See https://github.com/now/yard-value/issues
192
+
193
+ § Authors
194
+
195
+ Nikolai Weibull wrote the code, the tests, and this README.
71
196
  email: now@bitwi.se
72
197
  executables: []
73
198
  extensions: []
74
199
  extra_rdoc_files: []
75
200
  files:
76
201
  - lib/yard-value-1.0.rb
77
- - lib/yard-value/version.rb
202
+ - lib/yard-value-1.0/version.rb
78
203
  - test/unit/yard-value-1.0.rb
79
- - test/unit/yard-value/version.rb
204
+ - test/unit/yard-value-1.0/version.rb
80
205
  - README
81
206
  - Rakefile
82
207
  homepage: https://github.com/now/yard-value
@@ -87,21 +212,19 @@ rdoc_options: []
87
212
  require_paths:
88
213
  - lib
89
214
  required_ruby_version: !ruby/object:Gem::Requirement
90
- none: false
91
215
  requirements:
92
- - - ! '>='
216
+ - - '>='
93
217
  - !ruby/object:Gem::Version
94
218
  version: '0'
95
219
  required_rubygems_version: !ruby/object:Gem::Requirement
96
- none: false
97
220
  requirements:
98
- - - ! '>='
221
+ - - '>='
99
222
  - !ruby/object:Gem::Version
100
223
  version: '0'
101
224
  requirements: []
102
225
  rubyforge_project:
103
- rubygems_version: 1.8.10
226
+ rubygems_version: 2.0.0
104
227
  signing_key:
105
228
  specification_version: 4
106
- summary: YARD-Value provides YARD handlers for Value¹ objects.
229
+ summary: YARD-Value provides YARD¹ handlers for Value² objects.
107
230
  test_files: []