From ae907243570e85aa7b01b3428c585c2d8c5bc58a Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 6 Nov 2015 04:42:37 +0000 Subject: rbinstall.rb: compress man pages. * tool/rbinstall.rb (man): compress mdoc-style man pages, without Mdoc2Man. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52463 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- tool/rbinstall.rb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index 1a17f093a8..b14a4cdbd7 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb @@ -538,8 +538,13 @@ install?(:local, :comm, :man) do destname = ruby_install_name.sub(/ruby/, base.chomp(".#{section}")) destfile = File.join(destdir, "#{destname}.#{section}") - if $mantype == "doc" + if /\Adoc\b/ =~ $mantype install mdoc, destfile, :mode => $data_mode + case $mantype + when /\.(?:(gz)|bz2)\z/ + compress = $1 ? "gzip" : "bzip2" + system(compress, dest) + end else class << (w = []) alias print push -- cgit v1.2.3