Skip to content

Commit

Permalink
Merge pull request Homebrew#172478 from Homebrew/migrate-j
Browse files Browse the repository at this point in the history
  • Loading branch information
p-linnane committed Apr 29, 2024
2 parents ecf4f13 + ab3ff6b commit 7727810
Show file tree
Hide file tree
Showing 14 changed files with 1,326 additions and 0 deletions.
24 changes: 24 additions & 0 deletions Casks/j/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
cask "java@beta" do
arch arm: "aarch64", intel: "x64"

version "23,18"
sha256 arm: "af0f6fdaaa4422ba4c0fbd93c78ce448c9acdc0fd61fa536bc3b5ad1f914d393",
intel: "e6c136744b8903fe655a606c7ea8a587955596f8aa8d460c4bfb1837f0a01b6d"

url "https://download.java.net/java/early_access/jdk#{version.major}/#{version.csv.second}/GPL/openjdk-#{version.csv.first}-ea+#{version.csv.second}_macos-#{arch}_bin.tar.gz"
name "OpenJDK Early Access Java Development Kit"
desc "Early access development kit for the Java programming language"
homepage "https://jdk.java.net/"

livecheck do
url "https://jdk.java.net/#{version.major}/"
regex(%r{href=.*?/GPL/openjdk-(\d+)-ea\+(\d+)_macos-#{arch}_bin\.t}i)
strategy :page_match do |page, regex|
page.scan(regex).map { |match| "#{match[0]},#{match[1]}" }
end
end

artifact "jdk-#{version.csv.first}.jdk", target: "/Library/Java/JavaVirtualMachines/openjdk-#{version.csv.first}.jdk"

zap trash: "~/Library/Saved Application State/net.java.openjdk*.savedState"
end
19 changes: 19 additions & 0 deletions Casks/j/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
cask "julia@lts" do
version "1.6.7"
sha256 "e7b3ad41ec6dd1dd7e6d811ff71682680e056e0f82fc6b17710546630092915a"

url "https://julialang-s3.julialang.org/bin/mac/x64/#{version.major_minor}/julia-#{version}-mac64.dmg"
name "Julia"
desc "Programming language for technical computing"
homepage "https://julialang.org/"

livecheck do
url "https://julialang.org/downloads/"
regex(/\(LTS\)\s+release:\s+v?(\d+(?:\.\d+)+)/i)
end

app "Julia-#{version.major_minor}.app"
binary "#{appdir}/Julia-#{version.major_minor}.app/Contents/Resources/julia/bin/julia", target: "julia-lts"

zap trash: "~/.julia"
end
20 changes: 20 additions & 0 deletions Casks/j/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
cask "julia@nightly" do
arch arm: "aarch64", intel: "x86_64"

version "1.12"
sha256 :no_check

url "https://julialangnightlies-s3.julialang.org/bin/macos/#{arch}/julia-latest-macos-#{arch}.dmg"
name "Julia"
desc "Programming language for technical computing"
homepage "https://julialang.org/"

livecheck do
skip "No reliable version info"
end

app "Julia-#{version}.app"
binary "#{appdir}/Julia-#{version}.app/Contents/Resources/julia/bin/julia", target: "julia-nightly"

zap trash: "~/.julia"
end
46 changes: 46 additions & 0 deletions Casks/k/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
cask "kaleidoscope@2" do
version "2.4.5,1457,dec-20-2021"
sha256 "bbe5afc9f9292309527b6149e832c85460624e330c0768cd706d0629e0755611"

url "https://updates.kaleidoscope.app/v#{version.major}/prod/Kaleidoscope-#{version.tr(",", "-")}.app.zip"
name "Kaleidoscope v2"
desc "Spot and merge differences in text and image files or folders"
homepage "https://kaleidoscope.app/"

# Upstream also includes the newest version across all major versions, so we
# have to omit items with a different major version.
livecheck do
url "https://updates.kaleidoscope.app/v#{version.major}/prod/appcast"
regex(/Kaleidoscope[._-]v?(\d+(?:\.\d+)+)-(\d+)-(\w+(?:-\d+)*)\.app\.zip/i)
strategy :sparkle do |items, regex|
items.map do |item|
next if item.short_version&.split(".")&.first != version.major

match = item.url.match(regex)
next if match.blank?

"#{match[1]},#{match[2]},#{match[3]}"
end
end
end

auto_updates true
conflicts_with cask: %w[
kaleidoscope
kaleidoscope3
ksdiff
ksdiff2
]
depends_on macos: ">= :sierra"

app "Kaleidoscope.app"
binary "#{appdir}/Kaleidoscope.app/Contents/Resources/bin/ksdiff"

zap trash: [
"~/Library/Application Support/com.blackpixel.kaleidoscope",
"~/Library/Caches/com.blackpixel.kaleidoscope",
"~/Library/Caches/com.plausiblelabs.crashreporter.data/com.blackpixel.kaleidoscope",
"~/Library/Preferences/com.blackpixel.kaleidoscope.plist",
"~/Library/Saved Application State/com.blackpixel.kaleidoscope.savedState",
]
end
60 changes: 60 additions & 0 deletions Casks/k/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
cask "kaleidoscope@3" do
version "3.9,2176"
sha256 "036eea0cfd11797a72e37aa41af3c3acf65f7d6e9d5d5f5945444d49e232b44e"

url "https://updates.kaleidoscope.app/v#{version.major}/prod/Kaleidoscope-#{version.csv.first}-#{version.csv.second}.app.zip"
name "Kaleidoscope v3"
desc "Spot and merge differences in text and image files or folders"
homepage "https://kaleidoscope.app/"

# Upstream also includes the newest version across all major versions, so we
# have to omit items with a different major version.
livecheck do
url "https://updates.kaleidoscope.app/v#{version.major}/prod/appcast"
regex(/Kaleidoscope[._-]v?(\d+(?:\.\d+)+)[._-](\d+)\.app\.zip/i)
strategy :sparkle do |items, regex|
items.map do |item|
next if item.short_version&.split(".")&.first != version.major

match = item.url.match(regex)
next if match.blank?

"#{match[1]},#{match[2]}"
end
end
end

auto_updates true
conflicts_with cask: %w[
kaleidoscope
kaleidoscope2
ksdiff
ksdiff2
]
depends_on macos: ">= :big_sur"

app "Kaleidoscope.app"

postflight do
contents = "#{appdir}/Kaleidoscope.app/Contents"
system_command "#{contents}/Resources/Integration/scripts/install_ksdiff",
args: ["#{contents}/MacOS", "#{HOMEBREW_PREFIX}/bin"]
end

uninstall quit: "app.kaleidoscope.v#{version.major}",
pkgutil: "app.kaleidoscope.uninstall_ksdiff"

zap trash: [
"~/Library/Application Support/app.kaleidoscope.v*",
"~/Library/Application Support/com.blackpixel.kaleidoscope",
"~/Library/Application Support/Kaleidoscope",
"~/Library/Caches/app.kaleidoscope.v*",
"~/Library/Caches/com.blackpixel.kaleidoscope",
"~/Library/Caches/com.plausiblelabs.crashreporter.data/com.blackpixel.kaleidoscope",
"~/Library/Preferences/app.kaleidoscope.v*.plist",
"~/Library/Preferences/com.blackpixel.kaleidoscope.plist",
"~/Library/Saved Application State/app.kaleidoscope.v*.savedState",
"~/Library/Saved Application State/com.blackpixel.kaleidoscope.savedState",
"~/Library/WebKit/app.kaleidoscope.v*",
]
end
31 changes: 31 additions & 0 deletions Casks/k/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
cask "keepassxc@beta" do
arch arm: "arm64", intel: "x86_64"

version "2.7.7"
sha256 arm: "8681540627d03f70f683dc5acd79af8f42bba21425ffaf352c79eb5c31fb9712",
intel: "8e3a5d93a749569515604241ed21512f689d60c32fa1ed85f57f69042896b655"

url "https://github.com/keepassxreboot/keepassxc/releases/download/#{version}/KeePassXC-#{version}-#{arch}.dmg",
verified: "github.com/keepassxreboot/keepassxc/"
name "KeePassXC"
desc "Password manager app"
homepage "https://keepassxc.org/"

conflicts_with cask: "keepassxc"
depends_on macos: ">= :high_sierra"

app "KeePassXC.app"
binary "#{appdir}/KeePassXC.app/Contents/MacOS/keepassxc-cli"

uninstall quit: "org.keepassxc.keepassxc"

zap trash: [
"~/.keepassxc",
"~/Library/Application Support/CrashReporter/KeePassXC_*.plist",
"~/Library/Application Support/keepassxc",
"~/Library/Caches/org.keepassx.keepassxc",
"~/Library/Logs/DiagnosticReports/KeePassXC_*.crash",
"~/Library/Preferences/org.keepassx.keepassxc.plist",
"~/Library/Saved Application State/org.keepassx.keepassxc.savedState",
]
end
27 changes: 27 additions & 0 deletions Casks/k/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
cask "keka@beta" do
version "1.4.0-dev.r5383"
sha256 "d65027dd96f1069a5ec97f84aea399446a599840f428beea4ba8568037ffa4b2"

url "https://github.com/aonez/Keka/releases/download/v#{version}/Keka-#{version}.dmg",
verified: "github.com/aonez/Keka/"
name "Keka"
desc "File archiver"
homepage "https://www.keka.io/#beta"

livecheck do
url :url
regex(/^v?((?:\d+(?:\.\d+)+)-(?:beta|dev)(?:\.\w?\d+)?)?/i)
end

auto_updates true
conflicts_with cask: "keka"

app "Keka.app"

zap trash: [
"~/Library/Application Support/Keka",
"~/Library/Caches/com.aone.keka",
"~/Library/Preferences/com.aone.keka.plist",
"~/Library/Saved Application State/com.aone.keka.savedState",
]
end
32 changes: 32 additions & 0 deletions Casks/k/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
cask "kitty@nightly" do
version :latest
sha256 :no_check

url "https://github.com/kovidgoyal/kitty/releases/download/nightly/kitty-nightly.dmg"
name "kitty-nightly"
desc "GPU-based terminal emulator"
homepage "https://github.com/kovidgoyal/kitty"

conflicts_with cask: "kitty"
depends_on macos: ">= :sierra"

app "kitty.app"
# shim script (https://github.com/Homebrew/homebrew-cask/issues/18809)
shimscript = "#{staged_path}/kitty.wrapper.sh"
binary shimscript, target: "kitty"

preflight do
File.write shimscript, <<~EOS
#!/bin/sh
exec '#{appdir}/kitty.app/Contents/MacOS/kitty' "$@"
EOS
end

zap trash: [
"~/.config/kitty",
"~/Library/Caches/kitty",
"~/Library/Preferences/kitty",
"~/Library/Preferences/net.kovidgoyal.kitty.plist",
"~/Library/Saved Application State/net.kovidgoyal.kitty.savedState",
]
end
39 changes: 39 additions & 0 deletions Casks/l/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
cask "lando@edge" do
arch arm: "arm64", intel: "x64"

version "3.20.8"
sha256 arm: "111a4994b1b7badc8cb91a4a29f1f7064bc1e29ef0f225e3d040b72fbb6c0037",
intel: "43503628455d34da6e429cc7c88cc49acca14311a6756270241a96528061c528"

url "https://github.com/lando/lando/releases/download/v#{version}/lando-#{arch}-v#{version}.dmg",
verified: "github.com/lando/lando/"
name "Lando Edge"
desc "Local development environment and DevOps tool built on Docker"
homepage "https://docs.lando.dev/"

livecheck do
url :stable
regex(/^v?(\d+(?:\.\d+)+)$/i)
end

conflicts_with cask: "lando"
depends_on cask: "docker"

pkg "LandoInstaller.pkg",
choices: [
{
"choiceIdentifier" => "choiceDocker",
"choiceAttribute" => "selected",
"attributeSetting" => 0,
},
{
"choiceIdentifier" => "choiceLando",
"choiceAttribute" => "selected",
"attributeSetting" => 1,
},
]

uninstall pkgutil: "dev.lando.pkg.lando"

zap trash: "~/.lando"
end
Loading

0 comments on commit 7727810

Please sign in to comment.