[Groonga-commit] groonga/heroku-groonga-builder at 5652685 [build_kytea] Extract archive code

Back to archive index

Kouhei Sutou null+****@clear*****
Sun Sep 14 17:38:22 JST 2014


Kouhei Sutou	2014-06-05 13:04:06 +0900 (Thu, 05 Jun 2014)

  New Revision: 56526853ef651c8659aeb1a30e60be2d6962fac8
  https://github.com/groonga/heroku-groonga-builder/commit/56526853ef651c8659aeb1a30e60be2d6962fac8

  Message:
    Extract archive code

  Modified files:
    Rakefile

  Modified: Rakefile (+10 -4)
===================================================================
--- Rakefile    2014-06-05 13:02:42 +0900 (c471a8b)
+++ Rakefile    2014-06-05 13:04:06 +0900 (8632bda)
@@ -24,6 +24,10 @@ def groonga_version
   ENV["GROONGA_VERSION"] || "4.0.2"
 end
 
+def groonga_base_name
+  "groonga-#{groonga_version}"
+end
+
 def groonga_tag_name
   "v#{groonga_version}"
 end
@@ -56,8 +60,7 @@ def ensure_create_release
 end
 
 def build_groonga
-  base_name = "groonga-#{groonga_version}"
-  archive_name = "#{base_name}.tar.gz"
+  archive_name = "#{groonga_base_name}.tar.gz"
   sh("curl", "-O", "http://packages.groonga.org/source/groonga/#{archive_name}")
   sh("tar", "xf", archive_name)
 
@@ -74,8 +77,10 @@ def build_groonga
     sh("make", "-j4")
     sh("make", "install")
   end
+end
 
-  built_archive_name = "heroku-#{base_name}.tar.xz"
+def archive
+  built_archive_name = "heroku-#{groonga_base_name}.tar.xz"
   sh("tar", "cJf", built_archive_name, relative_install_prefix)
 
   build_archive_name
@@ -94,6 +99,7 @@ task :build do
   end
 
   ensure_create_release
-  archive_name = build_groonga
+  build_groonga
+  archive_name = archive
   release_archive(archive_name)
 end
-------------- next part --------------
HTML����������������������������...
다운로드 



More information about the Groonga-commit mailing list
Back to archive index