Skip to content

Commit

Permalink
scala: switch to openjdk@21
Browse files Browse the repository at this point in the history
  • Loading branch information
ZhongRuoyu committed Sep 19, 2024
1 parent 86b2565 commit 7b092fc
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Formula/s/scala.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
class Scala < Formula
desc "JVM-based programming language"
homepage "https://www.scala-lang.org/"
url "https://github.com/lampepfl/dotty/releases/download/3.5.0/scala3-3.5.0.tar.gz"
url "https://github.com/scala/scala3/releases/download/3.5.0/scala3-3.5.0.tar.gz"
sha256 "bacad178623f1940dae7d75c54c75aaf53f14f07ae99803be730a1d7d51a612d"
license "Apache-2.0"
revision 1

livecheck do
url "https://www.scala-lang.org/download/"
Expand All @@ -14,7 +15,9 @@ class Scala < Formula
sha256 cellar: :any_skip_relocation, all: "10318ae0301e9a1f7aebce892c512c20c1df2678a1df297568769ec80ae31fe7"
end

depends_on "openjdk"
# Switch back to `openjdk` when supported:
# https://docs.scala-lang.org/overviews/jdk-compatibility/overview.html
depends_on "openjdk@21"

conflicts_with "pwntools", because: "both install `common` binaries"

Expand All @@ -24,7 +27,7 @@ def install
libexec.install "maven2"
libexec.install "VERSION"
prefix.install "bin"
bin.env_script_all_files libexec/"bin", Language::Java.overridable_java_home_env
bin.env_script_all_files libexec/"bin", Language::Java.overridable_java_home_env("21")

# Set up an IntelliJ compatible symlink farm in 'idea'
idea = prefix/"idea"
Expand Down

0 comments on commit 7b092fc

Please sign in to comment.