public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Florian Schmaus" <flow@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lang/ammonite-repl-bin/
Date: Tue, 26 Jul 2022 11:20:32 +0000 (UTC)	[thread overview]
Message-ID: <1658834390.f688a09a2ce1015f91696dd80763dd8e052c57ed.flow@gentoo> (raw)

commit:     f688a09a2ce1015f91696dd80763dd8e052c57ed
Author:     Florian Schmaus <flow <AT> gentoo <DOT> org>
AuthorDate: Tue Jul 26 10:03:21 2022 +0000
Commit:     Florian Schmaus <flow <AT> gentoo <DOT> org>
CommitDate: Tue Jul 26 11:19:50 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f688a09a

dev-lang/ammonite-repl-bin: install for multiple Scala versions

Closes: https://github.com/gentoo/gentoo/pull/26602
Signed-off-by: Florian Schmaus <flow <AT> gentoo.org>

 dev-lang/ammonite-repl-bin/Manifest                |  4 +-
 .../ammonite-repl-bin-2.5.4-r1.ebuild              | 45 ++++++++++++++++++++++
 .../ammonite-repl-bin-2.5.4.ebuild                 | 26 -------------
 dev-lang/ammonite-repl-bin/metadata.xml            |  5 +++
 4 files changed, 53 insertions(+), 27 deletions(-)

diff --git a/dev-lang/ammonite-repl-bin/Manifest b/dev-lang/ammonite-repl-bin/Manifest
index 76d6281c64e6..1ac27e741ee0 100644
--- a/dev-lang/ammonite-repl-bin/Manifest
+++ b/dev-lang/ammonite-repl-bin/Manifest
@@ -1 +1,3 @@
-DIST ammonite-repl-bin-2.5.4 48438500 BLAKE2B 386ab32fc122267d17d377201a73e001ca40eb9c3254527e0819ae399cdcda90c5ada8d4773e16a1a930ba839e374dfd0d9848ccf1da75e5f6e385bf870f27a1 SHA512 cd1b382e2a5eb2ca93ad0640d9806e5770516f8fbd1c2a468e2bb333ab648916ed7b86efdf5d5e674176eee09532cf0a9b5af57021695c37b4862abb546966db
+DIST ammonite-repl-bin-2.5.4-2.13 48438500 BLAKE2B 386ab32fc122267d17d377201a73e001ca40eb9c3254527e0819ae399cdcda90c5ada8d4773e16a1a930ba839e374dfd0d9848ccf1da75e5f6e385bf870f27a1 SHA512 cd1b382e2a5eb2ca93ad0640d9806e5770516f8fbd1c2a468e2bb333ab648916ed7b86efdf5d5e674176eee09532cf0a9b5af57021695c37b4862abb546966db
+DIST ammonite-repl-bin-2.5.4-3.0 53445165 BLAKE2B 94791b9b616d6a1253fbb99455b2eb71ecb9768918b0e8c829f600c84e801dd53574b827fe32f606d4cf310f3f2655444d1979438ee459fa419d39820522f19d SHA512 498a858bc30c4a1479cc627559d066630cd0fd6ba9ae9e64607ce07246a216fd57de433e87a8b3b7511f4db143d227d9a0433166e5ba720ed38ae6dbd587f162
+DIST ammonite-repl-bin-2.5.4-3.1 54220925 BLAKE2B 104190bae8ae6d8efe3b3d43932ecf5f5075516b706dffca04a1fc3710edc476b2042b8b50036fd7719207dabd0771e3239030e866b48adad14a901d155c15c0 SHA512 5490d6bdc73bb6e48626e81acf3e8232697205252712505a31b5a3376d171c065854a5d552c910ac8c77f74e76eb84d34b5db5bb00b13fb53b5ba6394c22e920

diff --git a/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.4-r1.ebuild b/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.4-r1.ebuild
new file mode 100644
index 000000000000..7bda042dadbb
--- /dev/null
+++ b/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.4-r1.ebuild
@@ -0,0 +1,45 @@
+# Copyright 1999-2022 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 )
+"
+
+KEYWORDS="amd64 x86"
+LICENSE="MIT"
+SLOT="0"
+
+S="${WORKDIR}"
+
+RDEPEND=">=virtual/jre-1.8:*"
+
+IUSE="+scala2-13 scala3-0 +scala3-1"
+REQUIRED_USE="|| ( scala2-13 scala3-0 scala3-1 )"
+
+src_unpack() {
+	:
+}
+
+src_install() {
+	local last_amm
+	if use scala3-1; then
+		newbin "${DISTDIR}"/${P}-3.1 amm-3.1
+		last_amm=amm-3.1
+	fi
+	if use scala3-0; then
+		newbin "${DISTDIR}"/${P}-3.0 amm-3.0
+		last_amm=amm-3.0
+	fi
+	if use scala2-13; then
+		newbin "${DISTDIR}"/${P}-2.13 amm-2.13
+		last_amm=amm-2.13
+	fi
+	dosym $last_amm /usr/bin/amm
+}

diff --git a/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.4.ebuild b/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.4.ebuild
deleted file mode 100644
index 6cae7d9be42f..000000000000
--- a/dev-lang/ammonite-repl-bin/ammonite-repl-bin-2.5.4.ebuild
+++ /dev/null
@@ -1,26 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-SCALA_VERSION="2.13"
-
-DESCRIPTION="Scala language-based scripting and REPL"
-HOMEPAGE="https://ammonite.io/"
-SRC_URI="https://github.com/com-lihaoyi/Ammonite/releases/download/${PV}/${SCALA_VERSION}-${PV} -> ${P}"
-
-KEYWORDS="amd64 x86"
-LICENSE="MIT"
-SLOT="0"
-
-S="${WORKDIR}"
-
-RDEPEND=">=virtual/jre-1.8:*"
-
-src_unpack() {
-	:
-}
-
-src_install() {
-	newbin "${DISTDIR}"/${P} amm
-}

diff --git a/dev-lang/ammonite-repl-bin/metadata.xml b/dev-lang/ammonite-repl-bin/metadata.xml
index 29c1eb29b6d7..a6816afd69b6 100644
--- a/dev-lang/ammonite-repl-bin/metadata.xml
+++ b/dev-lang/ammonite-repl-bin/metadata.xml
@@ -14,4 +14,9 @@
 			<email>haoyi.sg@gmail.com</email>
 		</maintainer>
 	</upstream>
+	<use>
+		<flag name="scala2-13">Install Ammonite for Scala 2.13</flag>
+		<flag name="scala3-0">Install Ammonite for Scala 3.0</flag>
+		<flag name="scala3-1">Install Ammonite for Scala 3.1</flag>
+	</use>
 </pkgmetadata>


             reply	other threads:[~2022-07-26 11:20 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-26 11:20 Florian Schmaus [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-03-15  9:35 [gentoo-commits] repo/gentoo:master commit in: dev-lang/ammonite-repl-bin/ Florian Schmaus
2025-02-04 17:33 Florian Schmaus
2025-02-04 17:33 Florian Schmaus
2025-01-02 20:30 Florian Schmaus
2025-01-02 20:30 Florian Schmaus
2024-02-15 23:51 Sam James
2024-01-09 15:52 Florian Schmaus
2024-01-09 15:52 Florian Schmaus
2023-10-22 10:28 Florian Schmaus
2023-07-29 14:05 Florian Schmaus
2023-06-25 15:58 Florian Schmaus
2023-06-25 15:58 Florian Schmaus
2023-03-21 11:15 Florian Schmaus
2023-02-16  8:12 Florian Schmaus
2023-02-10 13:03 Florian Schmaus
2023-01-11  9:19 Florian Schmaus
2023-01-11  9:19 Florian Schmaus
2022-11-30  9:39 Florian Schmaus
2022-10-20 11:11 Florian Schmaus
2022-06-24 20:10 Florian Schmaus
2022-06-24 20:10 Florian Schmaus
2022-05-24  9:15 Florian Schmaus
2022-05-24  7:28 Florian Schmaus
2022-05-24  7:28 Florian Schmaus
2022-05-24  7:28 Florian Schmaus
2022-04-19  7:39 Florian Schmaus
2022-03-16 12:59 Florian Schmaus
2022-03-16 12:59 Florian Schmaus
2022-02-20  9:11 Florian Schmaus
2022-02-08 10:20 Florian Schmaus
2022-02-08 10:20 Florian Schmaus
2022-01-16  8:12 Florian Schmaus
2021-12-14 19:39 Florian Schmaus
2021-12-14 19:37 Florian Schmaus
2021-12-14 19:37 Florian Schmaus
2021-11-16 16:21 Florian Schmaus
2021-10-25 14:31 Florian Schmaus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1658834390.f688a09a2ce1015f91696dd80763dd8e052c57ed.flow@gentoo \
    --to=flow@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox