From 380272d903afa87b331403ebacb9f7f0f0ed0e3c Mon Sep 17 00:00:00 2001 From: Sutou Kouhei Date: Mon, 13 Nov 2023 14:22:52 +0900 Subject: [PATCH] Don't run "brew update" Closes GH-165 It may cause a Python related package update error. --- Gemfile | 17 ++++++++++++++++- ci/scripts/prepare-macos.sh | 1 - 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/Gemfile b/Gemfile index 66ab32d..04c9a18 100644 --- a/Gemfile +++ b/Gemfile @@ -20,5 +20,20 @@ source "https://rubygems.org" gem "rake" -gem "red-arrow-flight-sql" +# Use the version of red-arrow-flight-sql based on the available +# arrow-glib version +red_arrow_flight_sql_version = ">= 0" +IO.pipe do |input, output| + begin + pid = spawn("pkg-config", "--modversion", "arrow-flight-sql-glib", + out: output, + err: File::NULL) + output.close + Process.waitpid(pid) + arrow_flight_sql_glib_version = input.read.strip.sub(/-SNAPSHOT\z/, "") + red_arrow_flight_sql_version = "<= #{arrow_flight_sql_glib_version}" + rescue SystemCallError + end +end +gem "red-arrow-flight-sql", red_arrow_flight_sql_version gem "test-unit" diff --git a/ci/scripts/prepare-macos.sh b/ci/scripts/prepare-macos.sh index 4e051dc..630893f 100755 --- a/ci/scripts/prepare-macos.sh +++ b/ci/scripts/prepare-macos.sh @@ -25,6 +25,5 @@ sed \ -i "" \ -e "s/postgresql@[0-9]*/postgresql@${postgresql_version}/g" \ Brewfile -brew update brew bundle --verbose echo "$(brew --prefix postgresql@${postgresql_version})/bin" >> "${GITHUB_PATH}"