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

ruby-changes:48697

From: usa <ko1@a...>
Date: Thu, 16 Nov 2017 21:26:10 +0900 (JST)
Subject: [ruby-changes:48697] usa:r60813 (trunk): Old gem file had not been removed

usa	2017-11-16 21:26:04 +0900 (Thu, 16 Nov 2017)

  New Revision: 60813

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=60813

  Log:
    Old gem file had not been removed
    
    * common.mk (update-gems): `old.delete("gems/#{gem}")` always returns nil
      because when really downloading new gem, the filename is not in `old`.
      the real intention of this condition might be checking `old` is empty or not.

  Modified files:
    trunk/common.mk
Index: common.mk
===================================================================
--- common.mk	(revision 60812)
+++ common.mk	(revision 60813)
@@ -1134,7 +1134,7 @@ update-gems: PHONY https://github.com/ruby/ruby/blob/trunk/common.mk#L1134
 	    -e 'old = Dir.glob("gems/#{gem}-*.gem")' \
 	    -e 'gem = "#{gem}-#{ver}.gem"' \
 	    -e 'Downloader::RubyGems.download(gem, "gems", nil) and' \
-	    -e 'old.delete("gems/#{gem}") and' \
+	    -e '(old.delete("gems/#{gem}"); !old.empty?) and' \
 	    -e 'File.unlink(*old) and' \
 	    -e 'FileUtils.rm_rf(old.map{'"|n|"'n.chomp(".gem")})' \
 	    gems/bundled_gems

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

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