Source: yard Version: 0.8.7.4-1 Severity: wishlist Tags: patch User: reproducible-builds@lists.alioth.debian.org Usertags: toolchain X-Debbugs-Cc: reproducible-builds@lists.alioth.debian.org
Hi, While working on the "reproducible builds" effort [1], we have noticed that yard is not generating reproducible output. The attached patch adds the ability to disable the timestamp. [1]: https://wiki.debian.org/ReproducibleBuilds Regards, -- ,''`. : :' : Chris Lamb `. `'` la...@debian.org / chris-lamb.co.uk `-
diff --git a/lib/yard/cli/yardoc.rb b/lib/yard/cli/yardoc.rb index 4e4abb5..9567d54 100644 --- a/lib/yard/cli/yardoc.rb +++ b/lib/yard/cli/yardoc.rb @@ -26,6 +26,9 @@ module YARD # if the template supports it. default_attr :onefile, false + # @return [Boolean] whether we should add a timestamp to the output + default_attr :timestamp, true + # @return [CodeObjects::ExtraFileObject] the README file object rendered # along with objects attr_accessor :readme @@ -553,6 +556,10 @@ module YARD options.onefile = true end + opts.on('--no-timestamp', 'Do not output a timestamp') do + options.timestamp = false + end + opts.on('--list', 'List objects to standard out (implies -n)') do |format| self.generate = false self.list = true diff --git a/templates/default/layout/html/footer.erb b/templates/default/layout/html/footer.erb index e57a0f2..05a38ed 100644 --- a/templates/default/layout/html/footer.erb +++ b/templates/default/layout/html/footer.erb @@ -1,5 +1,5 @@ <div id="footer"> - Generated on <%= Time.now.strftime("%c") %> by + Generated<% if options.timestamp %> on <%= Time.now.strftime("%c") %><% end %> by <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a> <%= YARD::VERSION %> (ruby-<%= RUBY_VERSION %>). </div>
_______________________________________________ Reproducible-builds mailing list Reproducible-builds@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/reproducible-builds