Merge pull request #20210 from Homebrew/migrate-casks
[Homebrew/homebrew-cask-versions.git] / Casks / intellij-idea19.rb
blobe9aa4c577920193c12d13285d4d43638d4919224
1 cask "intellij-idea19" do
2   version "2019.3.5"
3   sha256 "196b739562012f2bbab22362d6a3094a1806acf1e1d0279b536f5f0327796a0d"
5   url "https://download.jetbrains.com/idea/ideaIU-#{version}.dmg"
6   name "IntelliJ IDEA Ultimate"
7   desc "IDE for JVM languages"
8   homepage "https://www.jetbrains.com/idea/"
10   deprecate! date: "2023-12-17", because: :discontinued
12   auto_updates true
14   app "IntelliJ IDEA.app"
16   uninstall_postflight do
17     ENV["PATH"].split(File::PATH_SEPARATOR).map { |path| File.join(path, "idea") }.each do |path|
18       if File.readable?(path) &&
19          File.readlines(path).grep(/# see com.intellij.idea.SocketLock for the server side of this interface/).any?
20         File.delete(path)
21       end
22     end
23   end
25   zap trash: [
26     "~/Library/Application Support/IntelliJIdea#{version.major_minor}",
27     "~/Library/Caches/IntelliJIdea#{version.major_minor}",
28     "~/Library/Logs/IntelliJIdea#{version.major_minor}",
29     "~/Library/Preferences/com.jetbrains.intellij.plist",
30     "~/Library/Preferences/IntelliJIdea#{version.major_minor}",
31     "~/Library/Saved Application State/com.jetbrains.intellij.savedState",
32   ]
33 end