From 59ee10754eddddb99e4a80b9e18aa12ed1b3d77a Mon Sep 17 00:00:00 2001 From: Xinglu Chen Date: Fri, 17 Sep 2021 10:04:49 +0200 Subject: import: Add 'generic-git' updater. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * guix/git.scm (ls-remote-refs): New procedure. * tests/git.scm ("remote-refs" "remote-refs: only tags"): New tests. * guix/import/git.scm: New file. * doc/guix.texi (Invoking guix refresh): Document it. * tests/import-git.scm: New test file. * Makefile.am (MODULES, SCM_TESTS): Register the new files. Co-authored-by: Sarah Morgensen Signed-off-by: Ludovic Courtès --- doc/guix.texi | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) (limited to 'doc') diff --git a/doc/guix.texi b/doc/guix.texi index 2fc9687910..6436e83a7c 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -11928,6 +11928,40 @@ the updater for @uref{https://launchpad.net, Launchpad} packages. @item generic-html a generic updater that crawls the HTML page where the source tarball of the package is hosted, when applicable. + +@item generic-git +a generic updater for packages hosted on Git repositories. It tries to +be smart about parsing Git tag names, but if it is not able to parse the +tag name and compare tags correctly, users can define the following +properties for a package. + +@itemize +@item @code{release-tag-prefix}: a regular expression for matching a prefix of +the tag name. + +@item @code{release-tag-suffix}: a regular expression for matching a suffix of +the tag name. + +@item @code{release-tag-version-delimiter}: a string used as the delimiter in +the tag name for separating the numbers of the version. + +@item @code{accept-pre-releases}: by default, the updater will ignore +pre-releases; to make it also look for pre-releases, set the this +property to @code{#t}. + +@end itemize + +@lisp +(package + (name "foo") + ;; ... + (properties + '((release-tag-prefix . "^release0-") + (release-tag-suffix . "[a-z]?$") + (release-tag-version-delimiter . ":")))) +@end lisp + + @end table For instance, the following command only checks for updates of Emacs -- cgit v1.2.3