summaryrefslogtreecommitdiffstats
path: root/install.rb
diff options
context:
space:
mode:
authornfagerlund <nick.fagerlund@gmail.com>2011-02-16 16:01:16 -0800
committernfagerlund <nick.fagerlund@gmail.com>2011-02-17 12:00:14 -0800
commitc61952001509768faa7fa09e7ddc2e7d86f2981f (patch)
tree448e10b55bc850d61142982564e7bfbf96ff65ba /install.rb
parent9e19d2267dfd254a12f1fe5fc37a524af8e1efc7 (diff)
downloadpuppet-c61952001509768faa7fa09e7ddc2e7d86f2981f.tar.gz
puppet-c61952001509768faa7fa09e7ddc2e7d86f2981f.tar.xz
puppet-c61952001509768faa7fa09e7ddc2e7d86f2981f.zip
(#1204) Move man generation task from install.rb to a rake task
Having this be commented-out code in the installer script doesn't really make sense for our workflow; we want to be able to regenerate these manpages at will and make sure they're always up-to-date. This will help us keep them in sync with the help text. This commit also changes the ronn invocation to specify a manual name and organization.
Diffstat (limited to 'install.rb')
-rwxr-xr-xinstall.rb53
1 files changed, 0 insertions, 53 deletions
diff --git a/install.rb b/install.rb
index 7627a8d11..72acb24f5 100755
--- a/install.rb
+++ b/install.rb
@@ -53,18 +53,6 @@ rescue LoadError
$haverdoc = false
end
-begin
- if $haverdoc
- ronn = %x{which ronn}
- $haveman = true
- else
- $haveman = false
- end
-rescue
- puts "Missing ronn; skipping man page creation"
- $haveman = false
-end
-
PREREQS = %w{openssl facter xmlrpc/client xmlrpc/server cgi}
MIN_FACTER_VERSION = 1.5
@@ -178,15 +166,6 @@ def prepare_installation
end
- if $haveman
- InstallOptions.man = true
- if $operatingsystem == "windows"
- InstallOptions.man = false
- end
- else
- InstallOptions.man = false
- end
-
InstallOptions.tests = true
ARGV.options do |opts|
@@ -198,9 +177,6 @@ def prepare_installation
opts.on('--[no-]ri', 'Prevents the creation of RI output.', 'Default off on mswin32.') do |onri|
InstallOptions.ri = onri
end
- opts.on('--[no-]man', 'Prevents the creation of man pages.', 'Default on.') do |onman|
- InstallOptions.man = onman
- end
opts.on('--[no-]tests', 'Prevents the execution of unit tests.', 'Default on.') do |ontest|
InstallOptions.tests = ontest
end
@@ -233,7 +209,6 @@ def prepare_installation
end
opts.on('--full', 'Performs a full installation. All', 'optional installation steps are run.') do |full|
InstallOptions.rdoc = true
- InstallOptions.man = true
InstallOptions.ri = true
InstallOptions.tests = true
InstallOptions.configs = true
@@ -368,33 +343,6 @@ def build_ri(files)
end
end
-def build_man(bins, sbins)
- return unless $haveman
- begin
- # Locate ronn
- ronn = %x{which ronn}
- ronn.chomp!
- # Create puppet.conf.5 man page
- %x{bin/puppetdoc --reference configuration > ./man/man5/puppetconf.5.ronn}
- %x{#{ronn} -r ./man/man5/puppetconf.5.ronn}
- File.move("./man/man5/puppetconf.5", "./man/man5/puppet.conf.5")
- File.unlink("./man/man5/puppetconf.5.ronn")
-
- # Create binary man pages
- binary = bins + sbins
- binary.each do |bin|
- b = bin.gsub( /(bin|sbin)\//, "")
- %x{#{bin} --help > ./man/man8/#{b}.8.ronn}
- %x{#{ronn} -r ./man/man8/#{b}.8.ronn}
- File.unlink("./man/man8/#{b}.8.ronn")
- end
-
-rescue SystemCallError
- $stderr.puts "Couldn't build man pages: " + $ERROR_INFO
- $stderr.puts "Continuing with install..."
- end
-end
-
def run_tests(test_list)
require 'test/unit/ui/console/testrunner'
$LOAD_PATH.unshift "lib"
@@ -488,7 +436,6 @@ prepare_installation
#run_tests(tests) if InstallOptions.tests
#build_rdoc(rdoc) if InstallOptions.rdoc
#build_ri(ri) if InstallOptions.ri
-#build_man(bins, sbins) if InstallOptions.man
do_configs(configs, InstallOptions.config_dir) if InstallOptions.configs
do_bins(sbins, InstallOptions.sbin_dir)
do_bins(bins, InstallOptions.bin_dir)