2015-12-18 09:15:28 +08:00
|
|
|
cask 'adobe-photoshop-lightroom' do
|
2018-01-05 04:35:13 +08:00
|
|
|
version '6.14'
|
|
|
|
sha256 'a9fba25594181acdb72d713fcbba5a1f3816ad18b974af2918e41e9ba5cc63ab'
|
2014-06-27 08:00:55 +08:00
|
|
|
|
2016-07-15 20:35:22 +08:00
|
|
|
url "http://swupdl.adobe.com/updates/oobe/aam20/mac/AdobeLightroom-#{version.major}.0/#{version}/setup.dmg"
|
2015-01-04 10:31:51 +08:00
|
|
|
name 'Adobe Photoshop Lightroom'
|
2015-06-29 14:32:18 +08:00
|
|
|
homepage 'https://www.adobe.com/products/photoshop-lightroom.html'
|
2014-06-27 08:00:55 +08:00
|
|
|
|
2017-05-21 06:23:32 +08:00
|
|
|
auto_updates true
|
2016-01-18 09:27:20 +08:00
|
|
|
depends_on cask: 'caskroom/versions/adobe-photoshop-lightroom600'
|
2015-11-30 15:20:10 +08:00
|
|
|
|
|
|
|
# staged_path not available in Installer/Uninstall Stanza, workaround by nesting with preflight/postflight
|
|
|
|
# see https://github.com/caskroom/homebrew-cask/pull/8887
|
|
|
|
# and https://github.com/caskroom/homebrew-versions/pull/296
|
|
|
|
|
|
|
|
preflight do
|
2016-12-18 02:46:36 +08:00
|
|
|
processes = system_command '/bin/launchctl', args: ['list']
|
|
|
|
|
|
|
|
if processes.stdout.lines.any? { |line| line =~ %r{^\d+\t\d\tcom.apple.SafariNotificationAgent$} }
|
|
|
|
system_command '/usr/bin/killall', args: ['-kill', 'SafariNotificationAgent']
|
|
|
|
end
|
|
|
|
|
2016-11-18 07:46:54 +08:00
|
|
|
system_command "#{staged_path}/AdobePatchInstaller.app/Contents/MacOS/AdobePatchInstaller",
|
|
|
|
args: [
|
|
|
|
'--mode=silent',
|
|
|
|
],
|
|
|
|
sudo: true
|
2015-11-30 15:20:10 +08:00
|
|
|
end
|
|
|
|
|
|
|
|
uninstall_preflight do
|
2016-11-18 23:51:50 +08:00
|
|
|
system_command 'brew', args: ['cask', 'uninstall', 'adobe-photoshop-lightroom600']
|
2015-11-30 15:20:10 +08:00
|
|
|
end
|
|
|
|
|
2017-06-21 09:47:44 +08:00
|
|
|
zap trash: [
|
|
|
|
'~/Library/Application Support/Adobe/Lightroom',
|
|
|
|
"~/Library/Preferences/com.adobe.Lightroom#{version.major}.plist",
|
|
|
|
]
|
2016-01-04 17:06:21 +08:00
|
|
|
|
2018-01-01 05:47:09 +08:00
|
|
|
caveats <<~EOS
|
|
|
|
Installation or Uninstallation may fail with Exit Code 19 (Conflicting Processes running) if Browsers, Safari Notification Service or SIMBL Services (e.g. Flashlight) are running or Adobe Creative Cloud or any other Adobe Products are already installed. See Logs in /Library/Logs/Adobe/Installers if Installation or Uninstallation fails, to identifify the conflicting processes.
|
|
|
|
EOS
|
2014-05-21 21:03:17 +08:00
|
|
|
end
|