hoe-yard 0.1.2 → 0.1.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: 1c08884cfdfa34fc9b0088bd4cbe442ca4432407
4
+ data.tar.gz: cd04a41bcb74a4fdfc3378a9e5ccf56bd9e1ed22
5
+ SHA512:
6
+ metadata.gz: 819ece30dd5ddc196d8b63fd534dde523345bf1c63be035b75704483bf51baf90fba6c570c49c8d3fcd45ee5c95b7fb367d5196922c4628b62ff34b5deb47805
7
+ data.tar.gz: dfaf810a56104367838ad02652f84596387387518b8e779ed7338bf0085b523bffa7fb760b16bfdbc1d2bd25e651e346c18a321bf51d6d5bd355176995fbc38c
@@ -0,0 +1,32 @@
1
+ === 0.1.3 / 2017-03-01
2
+
3
+ * Require [yard] ~> 0.8.
4
+ * Add `asciidoc` as one of the allowed markup providers (@dsisnero).
5
+
6
+ === 0.1.2 / 2010-01-22
7
+
8
+ * Renamed `yard_opts` to `yard_options`.
9
+ * No longer automatically add `yard` to the development dependencies
10
+ of a Hoe project.
11
+
12
+ === 0.1.1 / 2010-01-10
13
+
14
+ * Only add hoe-yard as a development dependency, if we are not in the
15
+ hoe-yard gem.
16
+ * Have the `yard` task generate documentation only for the files listed in
17
+ Manifest.txt.
18
+ * Have the `clobber_docs` task call `rm_r` when cleaning the `docs/`
19
+ directory.
20
+
21
+ === 0.1.0 / 2010-01-08
22
+
23
+ * Initial release:
24
+ * Automatically find the README and History files, irregardless of file
25
+ extension.
26
+ * Sets `has_rdoc` to `yard`.
27
+ * Sets `rdoc_options`.
28
+ * Sets `extra_rdoc_files`.
29
+ * Adds YARD and hoe-yard as development dependencies.
30
+ * Adds the `yard` and `docs` Rake tasks.
31
+
32
+ [yard]: http://yardoc.org/
@@ -1,5 +1,5 @@
1
- History.rdoc
1
+ History.md
2
2
  Manifest.txt
3
- README.rdoc
3
+ README.md
4
4
  Rakefile
5
5
  lib/hoe/yard.rb
@@ -1,10 +1,10 @@
1
- = hoe-yard
1
+ # hoe-yard
2
2
 
3
- * http://github.com/postmodern/hoe-yard
3
+ * http://github.com/postmodern/hoe-yard/
4
4
  * http://github.com/postmodern/hoe-yard/issues
5
5
  * Postmodern (postmodern.mod3 at gmail.com)
6
6
 
7
- == DESCRIPTION:
7
+ ## DESCRIPTION:
8
8
 
9
9
  A Hoe plugin for generating YARD documentation.
10
10
 
@@ -12,42 +12,42 @@ Using the Hoe YARD plugin, projects can begin generating YARD documentation
12
12
  instantly. Additionally, any resulting RubyGems will be properly configured
13
13
  to automatically generate YARD documentation upon installation.
14
14
 
15
- == FEATURES:
15
+ ## FEATURES:
16
16
 
17
17
  * Automatically find the README and History files, irregardless of file
18
18
  extension.
19
- * Sets +has_rdoc+ to +yard+.
20
- * Sets +rdoc_options+.
21
- * Sets +extra_rdoc_files+.
19
+ * Sets `has_rdoc` to `yard`.
20
+ * Sets `rdoc_options`.
21
+ * Sets `extra_rdoc_files`.
22
22
  * Adds hoe-yard as a development dependency.
23
- * Adds the +yard+ and +docs+ Rake tasks.
23
+ * Adds the `yard` and `docs` Rake tasks.
24
24
 
25
- == REQUIREMENTS:
25
+ ## REQUIREMENTS:
26
26
 
27
- * {yard}[http://yardoc.org/] >= 0.2.3.1
27
+ * [yard](http://yardoc.org/) >= 0.2.3.1
28
28
 
29
- == INSTALL:
29
+ ## INSTALL:
30
30
 
31
- $ sudo gem install hoe-yard
31
+ $ sudo gem install hoe-yard
32
32
 
33
- == USAGE:
33
+ ## USAGE:
34
34
 
35
- require 'rubygems'
36
- require 'hoe'
35
+ require 'rubygems'
36
+ require 'hoe'
37
37
 
38
- Hoe.plugin :yard
38
+ Hoe.plugin :yard
39
39
 
40
- Hoe.spec('my_project') do
41
- # ...
40
+ Hoe.spec('my_project') do
41
+ # ...
42
42
 
43
- self.yard_title = 'My Project'
44
- self.yard_markup = :markdown
45
- self.yard_opts = ['--protected']
43
+ self.yard_title = 'My Project'
44
+ self.yard_markup = :markdown
45
+ self.yard_opts = ['--protected']
46
46
 
47
- # ...
48
- end
47
+ # ...
48
+ end
49
49
 
50
- == LICENSE:
50
+ ## LICENSE:
51
51
 
52
52
  (The MIT License)
53
53
 
data/Rakefile CHANGED
@@ -3,19 +3,20 @@
3
3
  require 'rubygems'
4
4
  require 'hoe'
5
5
  require 'hoe/signing'
6
- require './lib/hoe/yard.rb'
6
+ $LOAD_PATH.unshift(File.expand_path('../lib',__FILE__))
7
7
 
8
8
  Hoe.plugin :yard
9
9
 
10
10
  Hoe.spec('hoe-yard') do
11
11
  self.version = Hoe::Yard::PLUGIN_VERSION
12
- self.developer('Postmodern', 'postmodern.mod3@gmail.com')
12
+ self.developer 'Postmodern', 'postmodern.mod3@gmail.com'
13
+ self.license 'MIT'
13
14
 
14
- self.yard_options = ['--protected']
15
+ self.yard_options = ['--markup', 'markdown', '--protected']
15
16
  self.remote_yard_dir = '/'
16
17
 
17
18
  self.extra_deps = [
18
- ['yard', '>=0.2.3.1']
19
+ ['yard', '~> 0.8']
19
20
  ]
20
21
  end
21
22
 
@@ -5,17 +5,17 @@ gem 'yard'
5
5
  ##
6
6
  # YARD plugin for hoe.
7
7
  #
8
- # === Tasks Provided:
8
+ # ### Tasks Provided:
9
9
  #
10
- # yard:: Generate YARD documentation
11
- # docs:: Generate YARD documentation
10
+ # * yard: Generate YARD documentation
11
+ # * docs: Generate YARD documentation
12
12
  #
13
13
  module Hoe::Yard
14
14
  # hoe-yard version
15
- PLUGIN_VERSION = '0.1.2'
15
+ PLUGIN_VERSION = '0.1.3'
16
16
 
17
17
  # Supported markups
18
- YARD_MARKUP = [:markdown, :texttile, :rdoc]
18
+ YARD_MARKUP = [:markdown, :texttile, :rdoc, :asciidoc]
19
19
 
20
20
  # File extensions indicating raw content
21
21
  YARD_RAW_EXTS = ['.txt', '.html']
@@ -24,14 +24,15 @@ module Hoe::Yard
24
24
  YARD_EXTS = {
25
25
  :markdown => ['.markdown', '.md'],
26
26
  :texttile => ['.texttile', '.tt'],
27
- :rdoc => ['.rdoc']
27
+ :rdoc => ['.rdoc'],
28
+ :asciidoc => ['.adoc']
28
29
  }
29
30
 
30
31
  # Title for the YARD documentation
31
32
  attr_accessor :yard_title
32
33
 
33
34
  # Markup style used in documentation, like textile, markdown or rdoc.
34
- # (default: +:rdoc+)
35
+ # (default: `:rdoc`)
35
36
  attr_accessor :yard_markup
36
37
 
37
38
  # Overrides the library used to process markup formatting
@@ -41,6 +42,9 @@ module Hoe::Yard
41
42
  # Options to pass to YARD
42
43
  attr_accessor :yard_options
43
44
 
45
+ #
46
+ # Initializes the hoe-yard plugin.
47
+ #
44
48
  def initialize_yard
45
49
  self.yard_title = Hoe.normalize_names(self.name).last + ' Documentation'
46
50
  self.yard_markup = nil
@@ -68,12 +72,12 @@ module Hoe::Yard
68
72
  end
69
73
  end
70
74
 
75
+ #
76
+ # Defines additional rake tasks.
77
+ #
71
78
  def define_yard_tasks
72
79
  require 'yard'
73
80
 
74
- # generate the YARD options
75
- opts = normalize_yard_opts
76
-
77
81
  desc "Remove YARD products"
78
82
  task :clobber_docs do
79
83
  if File.exists?(local_yard_dir)
@@ -81,6 +85,9 @@ module Hoe::Yard
81
85
  end
82
86
  end
83
87
 
88
+ # generate the YARD options
89
+ opts = normalize_yard_opts
90
+
84
91
  # define the yard task
85
92
  ::YARD::Rake::YardocTask.new do |t|
86
93
  t.files = self.spec.files.select { |path| path =~ /^lib\/.+\.rb$/ }
@@ -95,60 +102,84 @@ module Hoe::Yard
95
102
  protected
96
103
 
97
104
  #
98
- # Alias to +yard_options+.
105
+ # Alias to `yard_options`.
99
106
  #
100
- # @deprecated Use +yard_options+ instead.
107
+ # @deprecated Use `yard_options` instead.
101
108
  #
102
109
  def yard_opts
103
110
  self.yard_options
104
111
  end
105
112
 
106
113
  #
107
- # Alias to +yard_options=+.
114
+ # Alias to `yard_options=`.
108
115
  #
109
- # @deprecated Use +yard_options=+ instead.
116
+ # @deprecated Use `yard_options=` instead.
110
117
  #
111
118
  def yard_opts=(new_opts)
112
119
  self.yard_options = new_opts
113
120
  end
114
121
 
115
122
  #
116
- # Alias to <tt>Hoe#extra_rdoc_files</tt>.
123
+ # Alias to `Hoe#extra_rdoc_files`.
124
+ #
125
+ # @return [Array<String>]
126
+ # Additional files to include in the generated documentation.
117
127
  #
118
128
  def yard_files
119
129
  self.extra_rdoc_files
120
130
  end
121
131
 
122
132
  #
123
- # Alias to <tt>Hoe#extra_rdoc_files=</tt>.
133
+ # Alias to `Hoe#extra_rdoc_files=`.
134
+ #
135
+ # @param [Array<String>] new_files
136
+ # Additional files to include in the generated documentation.
137
+ #
138
+ # @return [Array<String>]
124
139
  #
125
140
  def yard_files=(new_files)
126
141
  self.extra_rdoc_files = new_files
127
142
  end
128
143
 
129
144
  #
130
- # Alias to <tt>Hoe#local_rdoc_dir</tt>.
145
+ # Alias to `Hoe#local_rdoc_dir`.
146
+ #
147
+ # @return [String]
148
+ # Relative path to the locally generated documentation directory.
131
149
  #
132
150
  def local_yard_dir
133
151
  self.local_rdoc_dir
134
152
  end
135
153
 
136
154
  #
137
- # Alias to <tt>Hoe#local_yard_dir=</tt>.
155
+ # Alias to `Hoe#local_yard_dir=`.
156
+ #
157
+ # @param [String] new_dir
158
+ # New relative path to the locally generated documentation directory.
159
+ #
160
+ # @return [String]
138
161
  #
139
162
  def local_yard_dir=(new_dir)
140
163
  self.local_rdoc_dir = new_dir
141
164
  end
142
165
 
143
166
  #
144
- # Alias to <tt>Hoe#remote_rdoc_dir</tt>.
167
+ # Alias to `Hoe#remote_rdoc_dir`.
168
+ #
169
+ # @return [String]
170
+ # Relative path to the desired remote documentation directory.
145
171
  #
146
172
  def remote_yard_dir
147
173
  self.remote_rdoc_dir
148
174
  end
149
175
 
150
176
  #
151
- # Alias to <tt>Hoe#remote_rdoc_dir=</tt>.
177
+ # Alias to `Hoe#remote_rdoc_dir=`.
178
+ #
179
+ # @param [String] new_dir
180
+ # New relative path to the desired remote documentation directory.
181
+ #
182
+ # @return [String]
152
183
  #
153
184
  def remote_yard_dir=(new_dir)
154
185
  self.remote_rdoc_dir = new_dir
@@ -158,6 +189,13 @@ module Hoe::Yard
158
189
  # Intuitively finds the file with the given _name_, using the current
159
190
  # YARD markup setting to guess the file extension.
160
191
  #
192
+ # @param [String] name
193
+ # The given file name.
194
+ #
195
+ # @return [String]
196
+ # The file sharing the same name, but ending with the appropriate markup
197
+ # file extension.
198
+ #
161
199
  def intuit_file_name(name)
162
200
  name = name.gsub(/\.[^\.]+$/,'')
163
201
  paths = Dir["#{name}.*"]
@@ -183,19 +221,22 @@ module Hoe::Yard
183
221
  # Generates the minimal amount of YARD options based on the YARD
184
222
  # settings.
185
223
  #
224
+ # @return [Array<String>]
225
+ #
186
226
  def normalize_yard_opts
187
- opts = self.yard_opts + ['--title', self.yard_title]
227
+ opts = self.yard_opts.dup
228
+ opts << '--title' << self.yard_title
188
229
 
189
230
  if self.yard_markup
190
- opts += ['--markup', self.yard_markup]
231
+ opts << '--markup' << self.yard_markup
191
232
  end
192
233
 
193
234
  if self.yard_markup_provider
194
- opts += ['--markup-provider', self.yard_markup_provider]
235
+ opts << '--markup-provider' << self.yard_markup_provider
195
236
  end
196
237
 
197
238
  unless (opts.include?('--quiet') || opts.include?('--verbose') || $DEBUG)
198
- opts += ['--quiet']
239
+ opts << '--quiet'
199
240
  end
200
241
 
201
242
  return opts
metadata CHANGED
@@ -1,129 +1,91 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: hoe-yard
3
- version: !ruby/object:Gem::Version
4
- version: 0.1.2
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.3
5
5
  platform: ruby
6
- authors:
6
+ authors:
7
7
  - Postmodern
8
8
  autorequire:
9
9
  bindir: bin
10
- cert_chain:
11
- - |
12
- -----BEGIN CERTIFICATE-----
13
- MIIDQDCCAiigAwIBAgIBADANBgkqhkiG9w0BAQUFADBGMRgwFgYDVQQDDA9wb3N0
14
- bW9kZXJuLm1vZDMxFTATBgoJkiaJk/IsZAEZF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tH/Qcrr1l9jfN0ehDs=
31
- -----END CERTIFICATE-----
32
-
33
- date: 2010-01-22 00:00:00 -08:00
34
- default_executable:
35
- dependencies:
36
- - !ruby/object:Gem::Dependency
10
+ cert_chain: []
11
+ date: 2017-03-02 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
37
14
  name: yard
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '0.8'
38
20
  type: :runtime
39
- version_requirement:
40
- version_requirements: !ruby/object:Gem::Requirement
41
- requirements:
42
- - - ">="
43
- - !ruby/object:Gem::Version
44
- version: 0.2.3.1
45
- version:
46
- - !ruby/object:Gem::Dependency
47
- name: rubyforge
48
- type: :development
49
- version_requirement:
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - ">="
53
- - !ruby/object:Gem::Version
54
- version: 2.0.3
55
- version:
56
- - !ruby/object:Gem::Dependency
57
- name: gemcutter
58
- type: :development
59
- version_requirement:
60
- version_requirements: !ruby/object:Gem::Requirement
61
- requirements:
62
- - - ">="
63
- - !ruby/object:Gem::Version
64
- version: 0.3.0
65
- version:
66
- - !ruby/object:Gem::Dependency
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '0.8'
27
+ - !ruby/object:Gem::Dependency
67
28
  name: hoe
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '3.16'
68
34
  type: :development
69
- version_requirement:
70
- version_requirements: !ruby/object:Gem::Requirement
71
- requirements:
72
- - - ">="
73
- - !ruby/object:Gem::Version
74
- version: 2.5.0
75
- version:
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '3.16'
76
41
  description: |-
77
42
  A Hoe plugin for generating YARD documentation.
78
-
43
+
79
44
  Using the Hoe YARD plugin, projects can begin generating YARD documentation
80
45
  instantly. Additionally, any resulting RubyGems will be properly configured
81
46
  to automatically generate YARD documentation upon installation.
82
- email:
47
+ email:
83
48
  - postmodern.mod3@gmail.com
84
49
  executables: []
85
-
86
50
  extensions: []
87
-
88
- extra_rdoc_files:
51
+ extra_rdoc_files:
52
+ - History.md
89
53
  - Manifest.txt
90
- - History.rdoc
91
- files:
92
- - History.rdoc
54
+ - README.md
55
+ files:
56
+ - History.md
93
57
  - Manifest.txt
94
- - README.rdoc
58
+ - README.md
95
59
  - Rakefile
96
60
  - lib/hoe/yard.rb
97
- has_rdoc: yard
98
- homepage: http://github.com/postmodern/hoe-yard
99
- licenses: []
100
-
61
+ homepage: http://github.com/postmodern/hoe-yard/
62
+ licenses:
63
+ - MIT
64
+ metadata: {}
101
65
  post_install_message:
102
- rdoc_options:
103
- - --protected
104
- - --title
105
- - HoeYard Documentation
106
- - --quiet
107
- require_paths:
66
+ rdoc_options:
67
+ - "--markup"
68
+ - markdown
69
+ - "--protected"
70
+ - "--title"
71
+ - TestHoe::TestYard Documentation
72
+ - "--quiet"
73
+ require_paths:
108
74
  - lib
109
- required_ruby_version: !ruby/object:Gem::Requirement
110
- requirements:
75
+ required_ruby_version: !ruby/object:Gem::Requirement
76
+ requirements:
111
77
  - - ">="
112
- - !ruby/object:Gem::Version
113
- version: "0"
114
- version:
115
- required_rubygems_version: !ruby/object:Gem::Requirement
116
- requirements:
78
+ - !ruby/object:Gem::Version
79
+ version: '0'
80
+ required_rubygems_version: !ruby/object:Gem::Requirement
81
+ requirements:
117
82
  - - ">="
118
- - !ruby/object:Gem::Version
119
- version: "0"
120
- version:
83
+ - !ruby/object:Gem::Version
84
+ version: '0'
121
85
  requirements: []
122
-
123
- rubyforge_project: hoe-yard
124
- rubygems_version: 1.3.5
86
+ rubyforge_project:
87
+ rubygems_version: 2.5.2
125
88
  signing_key:
126
- specification_version: 3
89
+ specification_version: 4
127
90
  summary: A Hoe plugin for generating YARD documentation
128
91
  test_files: []
129
-
data.tar.gz.sig DELETED
@@ -1,2 +0,0 @@
1
- q��o�HjY�h�Y=��\8���GLx'
2
- �pw���8������m+ߔ��Οے�6��H�1����o#v����'�LjZ?\7?H������2�y5�hu
@@ -1,26 +0,0 @@
1
- === 0.1.2 / 2010-01-22
2
-
3
- * Renamed +yard_opts+ to +yard_options+.
4
- * No longer automatically add +yard+ to the development dependencies
5
- of a Hoe project.
6
-
7
- === 0.1.1 / 2010-01-10
8
-
9
- * Only add hoe-yard as a development dependency, if we're not in the
10
- hoe-yard gem.
11
- * Have the +yard+ task generate documentation only for the files listed in
12
- Manifest.txt.
13
- * Have the +clobber_docs+ task call +rm_r+ when cleaning the <tt>docs/</tt>
14
- directory.
15
-
16
- === 0.1.0 / 2010-01-08
17
-
18
- * Initial release:
19
- * Automatically find the README and History files, irregardless of file
20
- extension.
21
- * Sets +has_rdoc+ to +yard+.
22
- * Sets +rdoc_options+.
23
- * Sets +extra_rdoc_files+.
24
- * Adds YARD and hoe-yard as development dependencies.
25
- * Adds the +yard+ and +docs+ Rake tasks.
26
-
metadata.gz.sig DELETED
Binary file