Permalink
Browse files

Add rake tasks to compile manpages.

A rake rule is used for creating manpages from ronn(1) files. To compile
the manpages run

    $ rake manpages
  • Loading branch information...
geoffgarside committed Nov 4, 2011
1 parent 96ea68c commit f91f8c4f9bbd355a6602d9b2ee87f71e95b8ce4d
Showing with 13 additions and 0 deletions.
  1. +13 −0 Rakefile
View
@@ -15,3 +15,16 @@ Cucumber::Rake::Task.new(:features) do |c|
end
task :default => [:spec, :features]
+
+rule(/\.[1-9]$/ => [proc { |tn| "#{tn}.ronn" }]) do |t|
+ name = Resque::Pool.name.sub('::','-').upcase
+ version = "%s %s" % [name, Resque::Pool::VERSION.upcase]
+
+ manual = '--manual "%s"' % name
+ organization = '--organization "%s"' % version
+ sh "ronn #{manual} #{organization} <#{t.source} >#{t.name}"
+end
+
+file 'man/resque-pool.1'
+file 'man/resque-pool-yml.5'
+task :manpages => ['man/resque-pool.1','man/resque-pool-yml.5']

0 comments on commit f91f8c4

Please sign in to comment.