Change Brew's Caskroom location.
This commit is contained in:
parent
a2521e8e83
commit
854ab0858d
|
@ -3,7 +3,7 @@
|
|||
[ ! -x "$(which brew 2>/dev/null)" -a ! -d /opt/homebrew-cask ] && exit 1
|
||||
|
||||
function __remove-cask {
|
||||
caskBasePath="/opt/homebrew-cask/Caskroom"
|
||||
caskBasePath="/usr/local/Caskroom"
|
||||
local cask="$1"
|
||||
local caskDirectory="$caskBasePath/$cask"
|
||||
local versionsToRemove="$(ls -r $caskDirectory | sed 1,1d)"
|
||||
|
|
|
@ -68,7 +68,7 @@ IO.popen('brew cask list') do |apps|
|
|||
# APPLICATION FILENAME
|
||||
appname = appname[1].strip
|
||||
|
||||
fullpath = `mdfind -onlyin /opt/homebrew-cask/Caskroom -onlyin /Applications -onlyin ~/Applications "#{appname}" | grep "#{appname}"`.strip
|
||||
fullpath = `mdfind -onlyin /usr/local/Caskroom -onlyin /Applications -onlyin ~/Applications "#{appname}" | grep "#{appname}"`.strip
|
||||
if File.exist?(fullpath)
|
||||
# GET APPLICATION VERSION WITH SPOTLIGHT
|
||||
if currentmatch = /([A-z0-9\.]+)/.match(`mdls "#{fullpath}" -name kMDItemVersion -raw`)
|
||||
|
|
Loading…
Reference in a new issue