* gnu/packages/tex.scm (texlive-alphalph): New variable.
---
gnu/packages/tex.scm | 45 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 45 insertions(+)
Toggle diff (65 lines)
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm
index a2f1de4e35..a6203300cb 100644
--- a/gnu/packages/tex.scm
+++ b/gnu/packages/tex.scm
@@ -27,6 +27,7 @@
;;; Copyright © 2023 Thomas Albers Raviola <thomas@thomaslabs.org>
;;; Copyright © 2023 John Kehayias <john.kehayias@protonmail.com>
;;; Copyright © 2023 Dominik Delgado Steuter <d@delgado.nrw>
+;;; Copyright © 2023 Felix Gruber <felgru@posteo.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -12067,6 +12068,50 @@ (define-public texlive-kastrup
LaTeX and plain TeX.")
(license (license:fsf-free "file:/binhex.dtx"))))
+(define-public texlive-alphalph
+ (let ((template (simple-texlive-package
+ "texlive-alphalph"
+ (list "doc/latex/alphalph/"
+ "source/latex/alphalph/"
+ "tex/generic/alphalph/")
+ (base32
+ "0ap59hmg0brg2wlh3bl77jxfxrk7hphhdal8cr05mby9bw35gffy"))))
+ (package
+ (inherit template)
+ (outputs '("out" "doc"))
+ (arguments
+ (substitute-keyword-arguments (package-arguments template)
+ ((#:tex-directory _ '())
+ "latex/alphalph")
+ ((#:build-targets _ '())
+ #~(list "alphalph.dtx"))
+ ((#:phases phases)
+ #~(modify-phases #$phases
+ (add-after 'unpack 'chdir
+ (lambda _
+ (chdir "source/latex/alphalph")))
+ (replace 'copy-files
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((origin (assoc-ref inputs "source"))
+ (source (string-append #$output
+ "/share/texmf-dist/source"))
+ (doc (string-append #$output:doc
+ "/share/texmf-dist/doc")))
+ (copy-recursively (string-append origin "/source") source)
+ (copy-recursively (string-append origin "/doc") doc))))))))
+ (propagated-inputs (list texlive-intcalc
+ texlive-infwarerr))
+ (home-page "https://ctan.org/pkg/alphalph")
+ (synopsis "Convert numbers to letters")
+ (description
+ "This package provides commands @code{\\alphalph} and
+@code{\\AlphAlph}. They are like @code{\\number} but the expansion
+consists of lowercase and uppercase letters respectively (1 to a, 26 to
+z, 27 to aa, 52 to zz, 53 to ba, 702 to zz, 703 to aaa, etc.).
+Alphalph's commands can be used as a replacement for LaTeX's
+@code{\\@@alph} and @code{\\@@Alph} macros.")
+ (license license:lppl1.3c+))))
+
(define-public texlive-latex-translations
(package
(inherit (simple-texlive-package
--
2.39.2