[前][次][番号順一覧][スレッド一覧]

ruby-changes:33856

From: nobu <ko1@a...>
Date: Wed, 14 May 2014 00:47:39 +0900 (JST)
Subject: [ruby-changes:33856] nobu:r45937 (trunk): make-snapshot: -package option

nobu	2014-05-14 00:47:33 +0900 (Wed, 14 May 2014)

  New Revision: 45937

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=45937

  Log:
    make-snapshot: -package option
    
    * tool/make-snapshot (package): add -package option to select
      packages to be made.

  Modified files:
    trunk/tool/make-snapshot
Index: tool/make-snapshot
===================================================================
--- tool/make-snapshot	(revision 45936)
+++ tool/make-snapshot	(revision 45937)
@@ -21,6 +21,7 @@ options: https://github.com/ruby/ruby/blob/trunk/tool/make-snapshot#L21
   -archname=NAME        make the basename of snapshots NAME
   -keep_temp            keep temporary working directory
   -patch_file=PATCH     apply PATCH file after export
+  -packages=PKG[,...]   make PKG packages (#{PACKAGES.keys.join(", ")})
 version:
   trunk, stable, branches/*, tags/*, X.Y.Z, X.Y.Z-pL
 each versions may be followed by optional @revision.
@@ -67,6 +68,12 @@ class Dir https://github.com/ruby/ruby/blob/trunk/tool/make-snapshot#L68
   end unless respond_to?(:mktmpdir)
 end
 
+$packages &&= $packages.split(/[, ]+/).tap {|pkg|
+  pkg -= PACKAGES.keys
+  pkg.empty? or abort "#{File.basename $0}: unknown packages - #{pkg.join(", ")}"
+}
+$packages ||= PACKAGES.keys
+
 $patch_file &&= File.expand_path($patch_file)
 path = ENV["PATH"].split(File::PATH_SEPARATOR)
 %w[YACC BASERUBY RUBY MV MINIRUBY].each do |var|
@@ -279,7 +286,8 @@ def package(rev, destdir) https://github.com/ruby/ruby/blob/trunk/tool/make-snapshot#L286
   end
 
   tarball = nil
-  return PACKAGES.collect do |mesg, (ext, *cmd)|
+  return $packages.collect do |mesg|
+    (ext, *cmd) = PACKAGES[mesg]
     File.directory?(destdir) or FileUtils.mkpath(destdir)
     file = File.join(destdir, "#{$archname||v}#{ext}")
     case ext

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]