|
1 | 1 | cask "intellij-idea-eap" do |
2 | 2 | arch arm: "-aarch64" |
3 | 3 |
|
4 | | - version "2025.3,253.28294.169" |
5 | | - sha256 arm: "d1ffaa48d91b70de4f4cfd98f430e11bbd64944b8399febc962cf0227a4463db", |
6 | | - intel: "ebb3f6885a546c91e8ac5aa204327c4ad31120beff077b8170c07c8455b00eb3" |
| 4 | + version "2025.3.2,253.30387.20" |
| 5 | + sha256 arm: "2cd8a11751b2cf5ef14dda201373387143ba1f9c784c8a0ce13f124fb5688d20", |
| 6 | + intel: "68e991c7c63203436e3ede8cb2f899ce5ee58e81476eecee8ec74724e756d64a" |
7 | 7 |
|
8 | 8 | url "https://download.jetbrains.com/idea/ideaIU-#{version.csv.second}#{arch}.dmg" |
9 | | - name "IntelliJ IDEA Ultimate" |
10 | | - desc "Java IDE by JetBrains" |
11 | | - homepage "https://www.jetbrains.com/idea/nextversion/" |
| 9 | + name "IntelliJ IDEA EAP" |
| 10 | + desc "IntelliJ IDEA Early Access Program" |
| 11 | + homepage "https://www.jetbrains.com/idea/nextversion" |
12 | 12 |
|
13 | 13 | livecheck do |
14 | | - url "https://data.services.jetbrains.com/products/releases?code=IIU&latest=true&type=eap" |
15 | | - strategy :page_match do |page| |
16 | | - JSON.parse(page)["IIU"].map do |release| |
17 | | - "#{release["version"]},#{release["build"]}" |
| 14 | + url "https://data.services.jetbrains.com/products/releases?code=IIU&release.type=eap" |
| 15 | + strategy :json do |json| |
| 16 | + json["IIU"]&.map do |release| |
| 17 | + version = release["version"] |
| 18 | + build = release["build"] |
| 19 | + next if version.blank? || build.blank? |
| 20 | + |
| 21 | + "#{version},#{build}" |
18 | 22 | end |
19 | 23 | end |
20 | 24 | end |
21 | 25 |
|
22 | 26 | auto_updates true |
23 | 27 |
|
24 | | - app "IntelliJ IDEA #{version.major_minor} EAP.app" |
25 | | - binary "#{appdir}/IntelliJ IDEA #{version.major_minor} EAP.app/Contents/MacOS/idea", target: "idea-eap" |
| 28 | + # The application path is often inconsistent between versions |
| 29 | + rename "IntelliJ IDEA*.app", "IntelliJ IDEA EAP.app" |
| 30 | + |
| 31 | + app "IntelliJ IDEA EAP.app" |
| 32 | + binary "#{appdir}/IntelliJ IDEA EAP.app/Contents/MacOS/idea", target: "idea-eap" |
26 | 33 |
|
27 | 34 | uninstall_postflight do |
28 | 35 | ENV["PATH"].split(File::PATH_SEPARATOR).map { |path| File.join(path, "idea") }.each do |path| |
|
34 | 41 | end |
35 | 42 |
|
36 | 43 | zap trash: [ |
37 | | - "~/Library/Application Support/JetBrains/IntelliJIdea#{version.major_minor}", |
38 | | - "~/Library/Caches/JetBrains/IntelliJIdea#{version.major_minor}", |
39 | | - "~/Library/Logs/JetBrains/IntelliJIdea#{version.major_minor}", |
| 44 | + "~/Library/Application Support/JetBrains/IntelliJIdea#{version.csv.first}", |
| 45 | + "~/Library/Caches/JetBrains/IntelliJIdea#{version.csv.first}", |
| 46 | + "~/Library/Logs/JetBrains/IntelliJIdea#{version.csv.first}", |
40 | 47 | "~/Library/Preferences/com.jetbrains.intellij-EAP.plist", |
41 | 48 | "~/Library/Saved Application State/com.jetbrains.intellij-EAP.savedState", |
42 | 49 | ] |
|
0 commit comments