Added custom @see YARD template
This commit is contained in:
parent
e075d25a91
commit
f6b65ba547
2
Rakefile
2
Rakefile
|
@ -99,7 +99,7 @@ task :ydoc do
|
|||
require File.join(File.dirname(__FILE__), 'lib', 'mongo')
|
||||
out = File.join('ydoc', Mongo::VERSION)
|
||||
FileUtils.rm_rf('ydoc')
|
||||
system "yardoc lib/**/*.rb lib/mongo/**/*.rb -o #{out} --title MongoRuby-#{Mongo::VERSION}"
|
||||
system "yardoc lib/**/*.rb lib/mongo/**/*.rb -p templates -o #{out} --title MongoRuby-#{Mongo::VERSION}"
|
||||
end
|
||||
|
||||
desc "Publish documentation to mongo.rubyforge.org"
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
<% if object.has_tag?(:see) %>
|
||||
<h3>See Also:</h3>
|
||||
<ul class="see">
|
||||
<% for tag in object.tags(:see) %>
|
||||
<% if tag.name =~ /^http/ %>
|
||||
<li><%= linkify(tag.name, tag.text || tag.name) %></li>
|
||||
<% else %>
|
||||
<li><%= tag.text %></li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% end %>
|
Loading…
Reference in New Issue