config: prettify sha method
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
This commit is contained in:
parent
d83076c07e
commit
647e7f1126
@ -30,7 +30,9 @@ module Homebrew extend self
|
||||
end
|
||||
|
||||
def sha
|
||||
sha = `cd #{HOMEBREW_REPOSITORY} && git rev-parse --verify HEAD 2> /dev/null`.chomp
|
||||
sha = HOMEBREW_REPOSITORY.cd do
|
||||
`git rev-parse --verify -q HEAD 2>/dev/null`.chomp
|
||||
end
|
||||
if sha.empty? then "(none)" else sha end
|
||||
end
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user