knife-cookbook-doc 0.7.0 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ZTkyZmVmN2UwMzM4Y2U4MjE0Y2Y1NDRhYTYzZTJhMjc0MDI1NWJhOQ==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
MWUyOTJhZWQ5ZDAxZDUwZWI2ZGI1OTU3MDM3MWUyOTVkZTg1NzBlZQ==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
ZTNlY2MzOTQ2MjI2NGQxNzM1ZmUzNjNiZDNhZmQ5ZTFhMGE5OWNjOGU2OWZh
|
10
|
+
MzNjZGM2MmIyZjExYTJhZjA0OTQzMDhkMDYxZGI0MTg4MjRiNTg5YjI1MjVl
|
11
|
+
ZGZiNWEwZmFmYzc1MDU4ZmQ3ODE3ZDEzMjc2Y2IwOWRlNTRiOWM=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
MTRlMTU0ZWRkZTU4NmMwMGFlZTQwODgzZjE3OTMzYjk3NTgxNWE1ZjY2YjQ5
|
14
|
+
N2NhNWM5ZWRkNjg2MjFlZDY2MTJhYmJkZGMxZGZmZGI4ZGRkODdmM2UwYmJk
|
15
|
+
YzkwNGY0NTI5ODExYTEzODQzZDBiZDM3YTllMTUwMzY0ODY4YmE=
|
data/CHANGELOG.md
CHANGED
@@ -0,0 +1,24 @@
|
|
1
|
+
require 'chef/resource/lwrp_base'
|
2
|
+
|
3
|
+
class DocumentingLWRPBase < ::Chef::Resource::LWRPBase
|
4
|
+
|
5
|
+
class << self
|
6
|
+
def attribute_specifications
|
7
|
+
@attribute_specifications ||= {}
|
8
|
+
end
|
9
|
+
|
10
|
+
def desc(description)
|
11
|
+
@description = "#{@description}#{description}\n"
|
12
|
+
end
|
13
|
+
|
14
|
+
def description
|
15
|
+
@description || ""
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
def self.attribute(attr_name, validation_opts={})
|
20
|
+
result = super(attr_name, validation_opts)
|
21
|
+
attribute_specifications[attr_name] = validation_opts
|
22
|
+
result
|
23
|
+
end
|
24
|
+
end
|
@@ -33,7 +33,7 @@ module KnifeCookbookDoc
|
|
33
33
|
top_level_descriptions[current_section] = lines
|
34
34
|
end
|
35
35
|
end
|
36
|
-
if @short_description.nil?
|
36
|
+
if @short_description.nil?
|
37
37
|
@short_description = first_sentence(description) || ""
|
38
38
|
end
|
39
39
|
end
|
@@ -62,27 +62,4 @@ module KnifeCookbookDoc
|
|
62
62
|
return nil
|
63
63
|
end
|
64
64
|
end
|
65
|
-
|
66
|
-
class DocumentingLWRPBase < ::Chef::Resource::LWRPBase
|
67
|
-
|
68
|
-
class << self
|
69
|
-
def attribute_specifications
|
70
|
-
@attribute_specifications ||= {}
|
71
|
-
end
|
72
|
-
|
73
|
-
def desc(description)
|
74
|
-
@description = "#{@description}#{description}\n"
|
75
|
-
end
|
76
|
-
|
77
|
-
def description
|
78
|
-
@description || ""
|
79
|
-
end
|
80
|
-
end
|
81
|
-
|
82
|
-
def self.attribute(attr_name, validation_opts={})
|
83
|
-
result = super(attr_name, validation_opts)
|
84
|
-
attribute_specifications[attr_name] = validation_opts
|
85
|
-
result
|
86
|
-
end
|
87
|
-
end
|
88
65
|
end
|
@@ -1,3 +1,5 @@
|
|
1
|
+
require 'knife_cookbook_doc/documenting_lwrp_base'
|
2
|
+
|
1
3
|
module KnifeCookbookDoc
|
2
4
|
class ResourceModel
|
3
5
|
|
@@ -121,27 +123,4 @@ module KnifeCookbookDoc
|
|
121
123
|
resource_class
|
122
124
|
end
|
123
125
|
end
|
124
|
-
|
125
|
-
class DocumentingLWRPBase < ::Chef::Resource::LWRPBase
|
126
|
-
|
127
|
-
class << self
|
128
|
-
def attribute_specifications
|
129
|
-
@attribute_specifications ||= {}
|
130
|
-
end
|
131
|
-
|
132
|
-
def desc(description)
|
133
|
-
@description = "#{@description}#{description}\n"
|
134
|
-
end
|
135
|
-
|
136
|
-
def description
|
137
|
-
@description || ""
|
138
|
-
end
|
139
|
-
end
|
140
|
-
|
141
|
-
def self.attribute(attr_name, validation_opts={})
|
142
|
-
result = super(attr_name, validation_opts)
|
143
|
-
attribute_specifications[attr_name] = validation_opts
|
144
|
-
result
|
145
|
-
end
|
146
|
-
end
|
147
126
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: knife-cookbook-doc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mathias Lafeldt
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2014-02-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: chef
|
@@ -72,6 +72,7 @@ files:
|
|
72
72
|
- lib/chef/knife/README.md.erb
|
73
73
|
- lib/chef/knife/cookbook_doc.rb
|
74
74
|
- lib/knife_cookbook_doc/attributes_model.rb
|
75
|
+
- lib/knife_cookbook_doc/documenting_lwrp_base.rb
|
75
76
|
- lib/knife_cookbook_doc/readme_model.rb
|
76
77
|
- lib/knife_cookbook_doc/recipe_model.rb
|
77
78
|
- lib/knife_cookbook_doc/resource_model.rb
|