diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-01-17 23:23:14 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2019-01-17 23:23:14 +0000 |
commit | 92c6072ef4183021b57ccbd3fbd7fefc17952866 (patch) | |
tree | 3c6a5a593130a937a3c965b11f232ab017336195 /tool/rbinstall.rb | |
parent | f550da512cefbe0283106ca839c4836a98efaf3a (diff) | |
download | ruby-92c6072ef4183021b57ccbd3fbd7fefc17952866.tar.gz |
rbinstall.rb: add --exclude option for install-nodoc
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66856 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'tool/rbinstall.rb')
-rwxr-xr-x | tool/rbinstall.rb | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index 4100fe17bf..b1ae31b601 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb @@ -40,6 +40,7 @@ def parse_args(argv = ARGV) $mflags = [] $install = [] $installed_list = nil + $exclude = [] $dryrun = false $rdocdir = nil $htmldir = nil @@ -67,6 +68,9 @@ def parse_args(argv = ARGV) opt.on('-i', '--install=TYPE', $install_procs.keys) do |ins| $install << ins end + opt.on('-x', '--exclude=TYPE', $install_procs.keys) do |exc| + $exclude << exc + end opt.on('--data-mode=OCTAL-MODE', OptionParser::OctalInteger) do |mode| $data_mode = mode end @@ -864,8 +868,7 @@ include FileUtils::NoWrite if $dryrun @fileutils_output = STDOUT @fileutils_label = '' -all = $install.delete(:all) -$install << :local << :ext if $install.empty? +$install << :all if $install.empty? installs = $install.map do |inst| if !(procs = $install_procs[inst]) || procs.empty? next warn("unknown install target - #{inst}") @@ -873,8 +876,7 @@ installs = $install.map do |inst| procs end installs.flatten! -installs.uniq! -installs |= $install_procs[:all] if all +installs -= $exclude.map {|exc| $install_procs[exc]}.flatten installs.each do |block| dir = Dir.pwd begin |