yard-mruby 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +9 -9
- data/.rspec +2 -2
- data/.travis.yml +4 -4
- data/CODE_OF_CONDUCT.md +13 -13
- data/Gemfile +4 -4
- data/LICENSE.txt +21 -21
- data/README.md +31 -31
- data/Rakefile +6 -6
- data/bin/console +14 -14
- data/bin/setup +7 -7
- data/exe/mrbdoc +5 -5
- data/lib/yard-mruby.rb +1 -1
- data/lib/yard/mruby.rb +9 -9
- data/lib/yard/mruby/cli.rb +1 -1
- data/lib/yard/mruby/cli/yardoc.rb +14 -14
- data/lib/yard/mruby/code_objects.rb +6 -6
- data/lib/yard/mruby/code_objects/define_object.rb +8 -8
- data/lib/yard/mruby/code_objects/function_object.rb +72 -72
- data/lib/yard/mruby/code_objects/header_base_object.rb +15 -15
- data/lib/yard/mruby/code_objects/header_object.rb +30 -30
- data/lib/yard/mruby/code_objects/headers_root.rb +14 -14
- data/lib/yard/mruby/code_objects/typedef_object.rb +8 -8
- data/lib/yard/mruby/handlers.rb +1 -1
- data/lib/yard/mruby/handlers/c.rb +4 -4
- data/lib/yard/mruby/handlers/c/header.rb +5 -5
- data/lib/yard/mruby/handlers/c/header/base.rb +30 -30
- data/lib/yard/mruby/handlers/c/header/define_handler.rb +23 -23
- data/lib/yard/mruby/handlers/c/header/function_handler.rb +33 -33
- data/lib/yard/mruby/handlers/c/header/header_decl_handler.rb +20 -20
- data/lib/yard/mruby/handlers/c/header/typedef_handler.rb +31 -31
- data/lib/yard/mruby/handlers/c/source.rb +7 -7
- data/lib/yard/mruby/handlers/c/source/base.rb +56 -56
- data/lib/yard/mruby/handlers/c/source/class_handler.rb +35 -35
- data/lib/yard/mruby/handlers/c/source/init_handler.rb +16 -16
- data/lib/yard/mruby/handlers/c/source/method_handler.rb +25 -25
- data/lib/yard/mruby/handlers/c/source/module_handler.rb +34 -34
- data/lib/yard/mruby/handlers/c/source/symbol_handler.rb +16 -16
- data/lib/yard/mruby/parser.rb +1 -1
- data/lib/yard/mruby/parser/c.rb +4 -4
- data/lib/yard/mruby/parser/c/directive_statement.rb +6 -6
- data/lib/yard/mruby/parser/c/header_parser.rb +49 -49
- data/lib/yard/mruby/parser/c/parser.rb +10 -10
- data/lib/yard/mruby/parser/c/source_parser.rb +9 -9
- data/lib/yard/mruby/tags.rb +2 -2
- data/lib/yard/mruby/templates.rb +9 -9
- data/lib/yard/mruby/templates/helpers.rb +1 -1
- data/lib/yard/mruby/templates/helpers/html_helper.rb +32 -32
- data/lib/yard/mruby/version.rb +5 -5
- data/sample/.gitignore +5 -5
- data/sample/.inch.yml +3 -3
- data/sample/.travis.yml +2 -2
- data/sample/.yardopts +4 -4
- data/sample/CODE_OF_CONDUCT.md +13 -13
- data/sample/Gemfile +5 -5
- data/sample/LICENSE.txt +21 -21
- data/sample/README.md +12 -12
- data/sample/build_config.rb +9 -9
- data/sample/include/sample.h +37 -37
- data/sample/mrbgem.rake +15 -15
- data/sample/mrblib/sample.rb +14 -14
- data/sample/src/sample.c +34 -34
- data/sample/test/sample_spec.rb +11 -11
- data/templates/default/fulldoc/html/full_list_functions.erb +10 -10
- data/templates/default/fulldoc/html/full_list_headers.erb +10 -10
- data/templates/default/fulldoc/html/setup.rb +62 -62
- data/templates/default/function_details/html/function_signature.erb +10 -10
- data/templates/default/function_details/html/header.erb +3 -3
- data/templates/default/function_details/html/source.erb +10 -10
- data/templates/default/function_details/setup.rb +12 -12
- data/templates/default/header/html/define_summary.erb +11 -11
- data/templates/default/header/html/function_details_list.erb +7 -7
- data/templates/default/header/html/function_summary.erb +12 -12
- data/templates/default/header/html/functions.erb +1 -1
- data/templates/default/header/html/header.erb +1 -1
- data/templates/default/header/html/includes.erb +1 -1
- data/templates/default/header/html/item_summary.erb +19 -19
- data/templates/default/header/html/pre_docstring.erb +1 -1
- data/templates/default/header/html/setup.rb +32 -32
- data/templates/default/header/html/typedef_summary.erb +11 -11
- data/templates/default/headersroot/html/headers_list.erb +6 -6
- data/templates/default/headersroot/html/setup.rb +10 -10
- data/templates/default/layout/html/footer.erb +5 -5
- data/templates/default/layout/html/setup.rb +52 -52
- data/templates/default/tags/html/iso.erb +3 -3
- data/templates/default/tags/html/mrbgem.erb +3 -3
- data/templates/default/tags/setup.rb +10 -10
- data/yard-mruby.gemspec +27 -27
- metadata +7 -7
@@ -1 +1 @@
|
|
1
|
-
<h2>Overview</h2>
|
1
|
+
<h2>Overview</h2>
|
@@ -1,32 +1,32 @@
|
|
1
|
-
include T('default/module')
|
2
|
-
include YARD::MRuby::Templates::Helpers::HTMLHelper
|
3
|
-
|
4
|
-
def init
|
5
|
-
sections :header, :pre_docstring, T('docstring'), :includes,
|
6
|
-
:function_summary, [:item_summary],
|
7
|
-
:define_summary, [T('docstring')],
|
8
|
-
:typedef_summary, [T('docstring')],
|
9
|
-
:function_details_list, [T('function_details')]
|
10
|
-
end
|
11
|
-
|
12
|
-
|
13
|
-
def function_listing
|
14
|
-
return @funcs if @funcs
|
15
|
-
|
16
|
-
@funcs = object.functions
|
17
|
-
@funcs
|
18
|
-
end
|
19
|
-
|
20
|
-
def define_listing
|
21
|
-
return @defines if @defines
|
22
|
-
|
23
|
-
@defines = object.defines
|
24
|
-
@defines
|
25
|
-
end
|
26
|
-
|
27
|
-
def typedef_listing
|
28
|
-
return @typedefs if @typedefs
|
29
|
-
|
30
|
-
@typedefs = object.typedefs
|
31
|
-
@typedefs
|
32
|
-
end
|
1
|
+
include T('default/module')
|
2
|
+
include YARD::MRuby::Templates::Helpers::HTMLHelper
|
3
|
+
|
4
|
+
def init
|
5
|
+
sections :header, :pre_docstring, T('docstring'), :includes,
|
6
|
+
:function_summary, [:item_summary],
|
7
|
+
:define_summary, [T('docstring')],
|
8
|
+
:typedef_summary, [T('docstring')],
|
9
|
+
:function_details_list, [T('function_details')]
|
10
|
+
end
|
11
|
+
|
12
|
+
|
13
|
+
def function_listing
|
14
|
+
return @funcs if @funcs
|
15
|
+
|
16
|
+
@funcs = object.functions
|
17
|
+
@funcs
|
18
|
+
end
|
19
|
+
|
20
|
+
def define_listing
|
21
|
+
return @defines if @defines
|
22
|
+
|
23
|
+
@defines = object.defines
|
24
|
+
@defines
|
25
|
+
end
|
26
|
+
|
27
|
+
def typedef_listing
|
28
|
+
return @typedefs if @typedefs
|
29
|
+
|
30
|
+
@typedefs = object.typedefs
|
31
|
+
@typedefs
|
32
|
+
end
|
@@ -1,11 +1,11 @@
|
|
1
|
-
<% if typedef_listing.size > 0 %>
|
2
|
-
<h2>Typedef Summary</h2>
|
3
|
-
<dl class="constants">
|
4
|
-
<% typedef_listing.each do |typedef| %>
|
5
|
-
<dt id="<%= anchor_for(typedef) %>" class="<%= typedef.has_tag?(:deprecated) ? 'deprecated' : '' %>"><small>typedef</small> <%= typedef.name %>
|
6
|
-
<%= yieldall :object => typedef %>
|
7
|
-
</dt>
|
8
|
-
<dd><pre class="code"><%#= format_constant typedef.value %></pre></dd>
|
9
|
-
<% end %>
|
10
|
-
</dl>
|
11
|
-
<% end %>
|
1
|
+
<% if typedef_listing.size > 0 %>
|
2
|
+
<h2>Typedef Summary</h2>
|
3
|
+
<dl class="constants">
|
4
|
+
<% typedef_listing.each do |typedef| %>
|
5
|
+
<dt id="<%= anchor_for(typedef) %>" class="<%= typedef.has_tag?(:deprecated) ? 'deprecated' : '' %>"><small>typedef</small> <%= typedef.name %>
|
6
|
+
<%= yieldall :object => typedef %>
|
7
|
+
</dt>
|
8
|
+
<dd><pre class="code"><%#= format_constant typedef.value %></pre></dd>
|
9
|
+
<% end %>
|
10
|
+
</dl>
|
11
|
+
<% end %>
|
@@ -1,6 +1,6 @@
|
|
1
|
-
<h2>All headers</h2>
|
2
|
-
<p class="children">
|
3
|
-
<% headers.each do |header| %>
|
4
|
-
<%= linkify(header, header.name(true)) %>
|
5
|
-
<% end %>
|
6
|
-
</p>
|
1
|
+
<h2>All headers</h2>
|
2
|
+
<p class="children">
|
3
|
+
<% headers.each do |header| %>
|
4
|
+
<%= linkify(header, header.name(true)) %>
|
5
|
+
<% end %>
|
6
|
+
</p>
|
@@ -1,10 +1,10 @@
|
|
1
|
-
def init
|
2
|
-
super
|
3
|
-
sections.push :headers_list
|
4
|
-
|
5
|
-
@namespace = object
|
6
|
-
end
|
7
|
-
|
8
|
-
def headers
|
9
|
-
object.headers
|
10
|
-
end
|
1
|
+
def init
|
2
|
+
super
|
3
|
+
sections.push :headers_list
|
4
|
+
|
5
|
+
@namespace = object
|
6
|
+
end
|
7
|
+
|
8
|
+
def headers
|
9
|
+
object.headers
|
10
|
+
end
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<div id="footer">
|
2
|
-
Generated on <%= Time.now.strftime("%c") %> by
|
3
|
-
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
4
|
-
<%= YARD::VERSION %> in <a href="https://github.com/sagmor/yard-mruby">mruby mode</a> <%= YARD::MRuby::VERSION %> (ruby-<%= RUBY_VERSION %>).
|
5
|
-
</div>
|
1
|
+
<div id="footer">
|
2
|
+
Generated on <%= Time.now.strftime("%c") %> by
|
3
|
+
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
4
|
+
<%= YARD::VERSION %> in <a href="https://github.com/sagmor/yard-mruby">mruby mode</a> <%= YARD::MRuby::VERSION %> (ruby-<%= RUBY_VERSION %>).
|
5
|
+
</div>
|
@@ -1,52 +1,52 @@
|
|
1
|
-
def init
|
2
|
-
super
|
3
|
-
end
|
4
|
-
|
5
|
-
#
|
6
|
-
# Append yard-cucumber stylesheet to yard core stylesheets
|
7
|
-
#
|
8
|
-
def stylesheets
|
9
|
-
super + %w(css/mruby.css)
|
10
|
-
end
|
11
|
-
|
12
|
-
#
|
13
|
-
# Append yard-cucumber javascript to yard core javascripts
|
14
|
-
#
|
15
|
-
def javascripts
|
16
|
-
super + %w(js/mruby.js)
|
17
|
-
end
|
18
|
-
|
19
|
-
#
|
20
|
-
# Append yard-cucumber specific menus 'features' and 'tags'
|
21
|
-
#
|
22
|
-
# 'features' and 'tags' are enabled by default.
|
23
|
-
#
|
24
|
-
# 'step definitions' and 'steps' may be enabled by setting up a value in
|
25
|
-
# yard configuration file '~/.yard/config'
|
26
|
-
#
|
27
|
-
# @example `~/.yard.config`
|
28
|
-
#
|
29
|
-
# yard-cucumber:
|
30
|
-
# menus: [ 'features', 'directories', 'tags', 'step definitions', 'steps' ]
|
31
|
-
#
|
32
|
-
def menu_lists
|
33
|
-
menus = super
|
34
|
-
last = menus.pop
|
35
|
-
|
36
|
-
menus.push({
|
37
|
-
type: 'header',
|
38
|
-
title: 'Headers',
|
39
|
-
search_title: 'Header List'
|
40
|
-
})
|
41
|
-
|
42
|
-
menus.push({
|
43
|
-
type: 'function',
|
44
|
-
title: 'Functions',
|
45
|
-
search_title: 'Function List'
|
46
|
-
})
|
47
|
-
|
48
|
-
menus.push last
|
49
|
-
|
50
|
-
menus
|
51
|
-
end
|
52
|
-
|
1
|
+
def init
|
2
|
+
super
|
3
|
+
end
|
4
|
+
|
5
|
+
#
|
6
|
+
# Append yard-cucumber stylesheet to yard core stylesheets
|
7
|
+
#
|
8
|
+
def stylesheets
|
9
|
+
super + %w(css/mruby.css)
|
10
|
+
end
|
11
|
+
|
12
|
+
#
|
13
|
+
# Append yard-cucumber javascript to yard core javascripts
|
14
|
+
#
|
15
|
+
def javascripts
|
16
|
+
super + %w(js/mruby.js)
|
17
|
+
end
|
18
|
+
|
19
|
+
#
|
20
|
+
# Append yard-cucumber specific menus 'features' and 'tags'
|
21
|
+
#
|
22
|
+
# 'features' and 'tags' are enabled by default.
|
23
|
+
#
|
24
|
+
# 'step definitions' and 'steps' may be enabled by setting up a value in
|
25
|
+
# yard configuration file '~/.yard/config'
|
26
|
+
#
|
27
|
+
# @example `~/.yard.config`
|
28
|
+
#
|
29
|
+
# yard-cucumber:
|
30
|
+
# menus: [ 'features', 'directories', 'tags', 'step definitions', 'steps' ]
|
31
|
+
#
|
32
|
+
def menu_lists
|
33
|
+
menus = super
|
34
|
+
last = menus.pop
|
35
|
+
|
36
|
+
menus.push({
|
37
|
+
type: 'header',
|
38
|
+
title: 'Headers',
|
39
|
+
search_title: 'Header List'
|
40
|
+
})
|
41
|
+
|
42
|
+
menus.push({
|
43
|
+
type: 'function',
|
44
|
+
title: 'Functions',
|
45
|
+
search_title: 'Function List'
|
46
|
+
})
|
47
|
+
|
48
|
+
menus.push last
|
49
|
+
|
50
|
+
menus
|
51
|
+
end
|
52
|
+
|
@@ -1,3 +1,3 @@
|
|
1
|
-
<% if object.has_tag?(:ISO) %>
|
2
|
-
<p class="tag_title"><strong>ISO</strong>: <%= object.tag(:ISO).name %></p>
|
3
|
-
<% end %>
|
1
|
+
<% if object.has_tag?(:ISO) %>
|
2
|
+
<p class="tag_title"><strong>ISO</strong>: <%= object.tag(:ISO).name %></p>
|
3
|
+
<% end %>
|
@@ -1,3 +1,3 @@
|
|
1
|
-
<% if object.has_tag?(:mrbgem) %>
|
2
|
-
<p class="tag_title"><strong>Required mrbgem</strong>: <%= object.tag(:mrbgem).name %></p>
|
3
|
-
<% end %>
|
1
|
+
<% if object.has_tag?(:mrbgem) %>
|
2
|
+
<p class="tag_title"><strong>Required mrbgem</strong>: <%= object.tag(:mrbgem).name %></p>
|
3
|
+
<% end %>
|
@@ -1,10 +1,10 @@
|
|
1
|
-
def init
|
2
|
-
super
|
3
|
-
|
4
|
-
sections << :iso
|
5
|
-
sections << :mrbgem
|
6
|
-
end
|
7
|
-
|
8
|
-
def param
|
9
|
-
super || tag(:param) if object.type == :function
|
10
|
-
end
|
1
|
+
def init
|
2
|
+
super
|
3
|
+
|
4
|
+
sections << :iso
|
5
|
+
sections << :mrbgem
|
6
|
+
end
|
7
|
+
|
8
|
+
def param
|
9
|
+
super || tag(:param) if object.type == :function
|
10
|
+
end
|
data/yard-mruby.gemspec
CHANGED
@@ -1,27 +1,27 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
lib = File.expand_path('../lib', __FILE__)
|
3
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
-
require 'yard/mruby/version'
|
5
|
-
|
6
|
-
Gem::Specification.new do |spec|
|
7
|
-
spec.name = "yard-mruby"
|
8
|
-
spec.version = YARD::MRuby::VERSION
|
9
|
-
spec.authors = ["Seba Gamboa"]
|
10
|
-
spec.email = ["me@sagmor.com"]
|
11
|
-
|
12
|
-
spec.summary = %q{Generate Yard documentation for MRuby projects.}
|
13
|
-
spec.description = %q{Generate Yard documentation for MRuby projects.}
|
14
|
-
spec.homepage = "https://github.com/sagmor/yard-mruby"
|
15
|
-
spec.license = "MIT"
|
16
|
-
|
17
|
-
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
18
|
-
spec.bindir = "exe"
|
19
|
-
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
20
|
-
spec.require_paths = ["lib"]
|
21
|
-
|
22
|
-
spec.add_dependency "yard"
|
23
|
-
|
24
|
-
spec.add_development_dependency "bundler", "~> 1.10"
|
25
|
-
spec.add_development_dependency "rake", "~> 10.0"
|
26
|
-
spec.add_development_dependency "rspec"
|
27
|
-
end
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'yard/mruby/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "yard-mruby"
|
8
|
+
spec.version = YARD::MRuby::VERSION
|
9
|
+
spec.authors = ["Seba Gamboa"]
|
10
|
+
spec.email = ["me@sagmor.com"]
|
11
|
+
|
12
|
+
spec.summary = %q{Generate Yard documentation for MRuby projects.}
|
13
|
+
spec.description = %q{Generate Yard documentation for MRuby projects.}
|
14
|
+
spec.homepage = "https://github.com/sagmor/yard-mruby"
|
15
|
+
spec.license = "MIT"
|
16
|
+
|
17
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
18
|
+
spec.bindir = "exe"
|
19
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
20
|
+
spec.require_paths = ["lib"]
|
21
|
+
|
22
|
+
spec.add_dependency "yard", "< 0.9.0"
|
23
|
+
|
24
|
+
spec.add_development_dependency "bundler", "~> 1.10"
|
25
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
26
|
+
spec.add_development_dependency "rspec"
|
27
|
+
end
|
metadata
CHANGED
@@ -1,29 +1,29 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yard-mruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Seba Gamboa
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-01-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: yard
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - "<"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: 0.9.0
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - "
|
24
|
+
- - "<"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
26
|
+
version: 0.9.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: bundler
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -183,7 +183,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
183
183
|
version: '0'
|
184
184
|
requirements: []
|
185
185
|
rubyforge_project:
|
186
|
-
rubygems_version: 2.
|
186
|
+
rubygems_version: 2.5.2
|
187
187
|
signing_key:
|
188
188
|
specification_version: 4
|
189
189
|
summary: Generate Yard documentation for MRuby projects.
|