Navigation Menu

Skip to content

Commit

Permalink
Use build.with? instead of ARGV.include? as much as possible
Browse files Browse the repository at this point in the history
  • Loading branch information
cosmo0920 committed Jun 26, 2015
1 parent 5241164 commit 89fc27d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions mroonga.rb
Expand Up @@ -13,9 +13,9 @@ class Mroonga < Formula
depends_on "groonga"
end

if ARGV.include?("--use-homebrew-mysql")
if build.with?("use-homebrew-mysql")
depends_on "mysql"
elsif ARGV.include?("--use-homebrew-mariadb")
elsif build.with?("use-homebrew-mariadb")
depends_on "mariadb"
end

Expand All @@ -34,9 +34,9 @@ def patches
end

def install
if ARGV.include?("--use-homebrew-mysql")
if build.with?("use-homebrew-mysql")
mysql_formula_name = "mysql"
elsif ARGV.include?("--use-homebrew-mariadb")
elsif build.with?("use-homebrew-mariadb")
mysql_formula_name = "mariadb"
else
mysql_formula_name = nil
Expand Down

0 comments on commit 89fc27d

Please sign in to comment.