summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Schmaus <flow@gentoo.org>2023-06-25 17:58:06 +0200
committerFlorian Schmaus <flow@gentoo.org>2023-06-25 17:58:50 +0200
commit40a1389e09e54f073ddba73f60cdc322eedad2ea (patch)
tree198c34cbe51ad8a6325cfd200920afc31d781da2 /dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.9.ebuild
parentdev-java/mill-bin: add 0.11.1 (diff)
downloadgentoo-40a1389e09e54f073ddba73f60cdc322eedad2ea.tar.gz
gentoo-40a1389e09e54f073ddba73f60cdc322eedad2ea.tar.bz2
gentoo-40a1389e09e54f073ddba73f60cdc322eedad2ea.zip
dev-lang/ammonite-repl-bin: add 2.5.9
Signed-off-by: Florian Schmaus <flow@gentoo.org>
Diffstat (limited to 'dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.9.ebuild')
-rw-r--r--dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.9.ebuild49
1 files changed, 49 insertions, 0 deletions
diff --git a/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.9.ebuild b/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.9.ebuild
new file mode 100644
index 000000000000..103d0f16b926
--- /dev/null
+++ b/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.9.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DESCRIPTION="Scala language-based scripting and REPL"
+HOMEPAGE="https://ammonite.io/"
+
+SRC_URI="
+ scala2-13? ( https://github.com/com-lihaoyi/Ammonite/releases/download/${PV}/2.13-${PV} -> ${P}-2.13 )
+ scala3-0? ( https://github.com/com-lihaoyi/Ammonite/releases/download/${PV}/3.0-${PV} -> ${P}-3.0 )
+ scala3-1? ( https://github.com/com-lihaoyi/Ammonite/releases/download/${PV}/3.1-${PV} -> ${P}-3.1 )
+ scala3-2? ( https://github.com/com-lihaoyi/Ammonite/releases/download/${PV}/3.2-${PV} -> ${P}-3.2 )
+"
+
+KEYWORDS="~amd64 ~x86"
+LICENSE="MIT"
+SLOT="0"
+
+S="${WORKDIR}"
+
+RDEPEND=">=virtual/jre-1.8:*"
+
+IUSE="+scala2-13 scala3-0 scala3-1 +scala3-2"
+
+src_unpack() {
+ :
+}
+
+src_install() {
+ local last_amm
+ local scala_versions=(2.13 3.{0,1,2})
+ local scala_version
+ for scala_version in ${scala_versions[@]}; do
+ local use_flag=scala${scala_version/./-}
+
+ if ! use ${use_flag}; then
+ continue
+ fi
+
+ local amm_bin
+ amm_bin="amm-${scala_version}"
+
+ newbin "${DISTDIR}/${P}-${scala_version}" ${amm_bin}
+ last_amm=${amm_bin}
+ done
+
+ dosym $last_amm /usr/bin/amm
+}