Reduce nesting in 'brew up'.
This commit is contained in:
parent
b9bb078642
commit
07914a48ee
6
bin/brew
6
bin/brew
@ -163,7 +163,8 @@ begin
|
|||||||
end
|
end
|
||||||
|
|
||||||
when 'up', 'update'
|
when 'up', 'update'
|
||||||
if system "/usr/bin/which -s git"
|
abort "Please `brew install git' first." unless system "/usr/bin/which -s git"
|
||||||
|
|
||||||
require 'update'
|
require 'update'
|
||||||
updater = RefreshBrew.new
|
updater = RefreshBrew.new
|
||||||
old_revision = updater.current_revision
|
old_revision = updater.current_revision
|
||||||
@ -189,9 +190,6 @@ begin
|
|||||||
puts "No formulae were updated." unless updater.pending_formulae_changes?
|
puts "No formulae were updated." unless updater.pending_formulae_changes?
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
else
|
|
||||||
abort "Please `brew install git' first."
|
|
||||||
end
|
|
||||||
|
|
||||||
when 'ln', 'link'
|
when 'ln', 'link'
|
||||||
ARGV.kegs.each {|keg| puts "#{keg.link} links created for #{keg}"}
|
ARGV.kegs.each {|keg| puts "#{keg.link} links created for #{keg}"}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user