aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd
diff options
context:
space:
mode:
authorJack Nagel2014-07-06 14:10:52 -0500
committerJack Nagel2014-07-06 14:10:52 -0500
commit44254aa9cf967bb558a8722b799c280c32e8e12c (patch)
treeafa1d0606c04fce70646a87ad987a5b7d18642e8 /Library/Homebrew/cmd
parentdae83fc89586938ca6bebcf22c1c38022bb91303 (diff)
downloadbrew-44254aa9cf967bb558a8722b799c280c32e8e12c.tar.bz2
Remove redundant "which git" guards
There is always a git executable on PATH due to the git wrapper in Library/Contributions/cmd. The wrapper will notify the user if there is not a real git installed.
Diffstat (limited to 'Library/Homebrew/cmd')
-rw-r--r--Library/Homebrew/cmd/info.rb2
-rw-r--r--Library/Homebrew/cmd/tap.rb2
-rw-r--r--Library/Homebrew/cmd/update.rb1
3 files changed, 1 insertions, 4 deletions
diff --git a/Library/Homebrew/cmd/info.rb b/Library/Homebrew/cmd/info.rb
index 5308fc939..1ce1966e1 100644
--- a/Library/Homebrew/cmd/info.rb
+++ b/Library/Homebrew/cmd/info.rb
@@ -54,7 +54,7 @@ module Homebrew
end
def github_fork
- if which 'git' and (HOMEBREW_REPOSITORY/".git").directory?
+ if (HOMEBREW_REPOSITORY/".git").directory?
if `git remote -v` =~ %r{origin\s+(https?://|git(?:@|://))github.com[:/](.+)/homebrew}
$2
end
diff --git a/Library/Homebrew/cmd/tap.rb b/Library/Homebrew/cmd/tap.rb
index 8ed45b239..c3fb1ed5e 100644
--- a/Library/Homebrew/cmd/tap.rb
+++ b/Library/Homebrew/cmd/tap.rb
@@ -12,8 +12,6 @@ module Homebrew
end
def install_tap user, repo
- raise "brew install git" unless which 'git'
-
# we special case homebrew so users don't have to shift in a terminal
repouser = if user == "homebrew" then "Homebrew" else user end
user = "homebrew" if user == "Homebrew"
diff --git a/Library/Homebrew/cmd/update.rb b/Library/Homebrew/cmd/update.rb
index b85a355b8..4040d343e 100644
--- a/Library/Homebrew/cmd/update.rb
+++ b/Library/Homebrew/cmd/update.rb
@@ -9,7 +9,6 @@ module Homebrew
Use `brew upgrade <formula>`.
EOS
end
- abort "Please `brew install git' first." unless which "git"
# ensure GIT_CONFIG is unset as we need to operate on .git/config
ENV.delete('GIT_CONFIG')