From: Nicolas Graves via Guix-patches via <guix-patches@gnu.org>
To: 67897@debbugs.gnu.org
Cc: ludo@gnu.org, ngraves@ngraves.fr
Subject: [bug#67897] [PATCH] guix: import: composer: Fix latest-release function.
Date: Tue, 19 Dec 2023 11:38:02 +0100 [thread overview]
Message-ID: <20231219103802.15994-1-ngraves@ngraves.fr> (raw)
* guix/import/composer.scm (latest-release): Support additional
version argument. Replace package-name by composer-package-name.
Change-Id: Ia55a841c8fe23e2d9c35ce80ab695c325ad8f962
---
guix/import/composer.scm | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/guix/import/composer.scm b/guix/import/composer.scm
index 1ad608964b..069a950f90 100644
--- a/guix/import/composer.scm
+++ b/guix/import/composer.scm
@@ -243,14 +243,14 @@ (define (php-package? package)
(eq? (package-build-system package) composer-build-system)
(string-prefix? "php-" (package-name package))))
-(define (latest-release package)
+(define* (latest-release package #:key (version #f))
"Return an <upstream-source> for the latest release of PACKAGE."
(let* ((php-name (guix-package->composer-name package))
- (package (composer-fetch php-name))
+ (package (composer-fetch php-name #:version version))
(version (composer-package-version package))
(url (composer-source-url (composer-package-source package))))
(upstream-source
- (package (package-name package))
+ (package (composer-package-name package))
(version version)
(urls (list url)))))
--
2.41.0
reply other threads:[~2023-12-19 10:39 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20231219103802.15994-1-ngraves@ngraves.fr \
--to=guix-patches@gnu.org \
--cc=67897@debbugs.gnu.org \
--cc=ludo@gnu.org \
--cc=ngraves@ngraves.fr \
/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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.