gnu: emacs-bui: Use GIT-FILE-NAME.
[jackhill/guix/guix.git] / gnu / packages / emacs-xyz.scm
index df7a22c..4297331 100644 (file)
@@ -1538,7 +1538,7 @@ Maps directly inside Emacs.")
                 (uri (git-reference
                       (url "https://github.com/ppareit/graphviz-dot-mode.git")
                       (commit commit)))
-                (file-name (string-append name "-" version "-checkout"))
+                (file-name (git-file-name name version))
                 (sha256
                  (base32
                   "0j1r2rspaakw37b0mx7pwpvdsvixq9sw3xjbww5piihzpdxz58z1"))))
@@ -1729,7 +1729,7 @@ and stored in memory.")
               (uri (git-reference
                     (url "https://notabug.org/alezost/emacs-bui.git")
                     (commit (string-append "v" version))))
-              (file-name (string-append name "-" version "-checkout"))
+              (file-name (git-file-name name version))
               (sha256
                (base32
                 "0sszdl4kvqbihdh8d7mybpp0d8yw2p3gyiipjcxz9xhvvmw3ww4x"))))
@@ -4887,7 +4887,7 @@ provide the historic behavior of @code{flet}, as well as
               (uri (git-reference
                     (url "https://github.com/sigma/mocker.el.git")
                     (commit (string-append "v" version))))
-              (file-name (string-append name "-" version "-checkout"))
+              (file-name (git-file-name name version))
               (sha256
                (base32
                 "1lav7am41v63xgavq8pr88y828jmd1cxd4prjq7jlbxm6nvrwxh2"))))
@@ -6163,7 +6163,7 @@ abbreviation and automatically expand it into function templates.")
          (uri (git-reference
                (url "https://github.com/AndreaCrotti/yasnippet-snippets")
                (commit commit)))
-         (file-name (string-append name "-" version "-checkout"))
+         (file-name (git-file-name name version))
          (sha256
           (base32
            "1m935zgglw0iakzrixld5rcjz3wnj84f8wy2mvc3pggjri9l0qr9"))))
@@ -7720,14 +7720,13 @@ editing RPM spec files.")
     (version "0.18")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append
-             "https://github.com/syohex/emacs-git-messenger/archive/"
-             version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/syohex/emacs-git-messenger.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "17mqki6g0wx46fn7dcbcc2pjxik7vvrcb1j9jzxim8b9psbsbnp9"))))
+        (base32 "04fnby2nblk8l70gv09asxkmnn53fh1pdfs77ix44npp99fyw8ix"))))
     (build-system emacs-build-system)
     (propagated-inputs
      `(("emacs-popup" ,emacs-popup)))
@@ -7749,13 +7748,13 @@ internally.")
     (version "0.5.0")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append "https://github.com/tumashu/gitpatch/archive/"
-                           "v" version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/tumashu/gitpatch.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "1yj6pmic541lcnscjin300k380qp9xdfprs55xg1q57jrkq6f6k7"))))
+        (base32 "1jj12pjwza6cq8a3kr8nqnmm3vxs0wam8h983irry4xr4ifywsn4"))))
     (build-system emacs-build-system)
     (home-page "https://github.com/tumashu/gitpatch")
     (synopsis "Mail git patch from Emacs")
@@ -7797,13 +7796,13 @@ the nick color and the background color
     (version "2.0.0")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append "https://github.com/hrs/engine-mode/archive/"
-                           "v" version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/hrs/engine-mode.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "1vm4p7pcp1vnwwxvps1bhm7i7hkabqqxl898knxf2hqvxys76684"))))
+        (base32 "02xas46nl28mascqsyr1zcd4hn15bh0fjv2xlxv1kmrj0pis94ml"))))
     (build-system emacs-build-system)
     (synopsis "Minor mode for defining and querying search engines")
     (description "@code{engine-mode} is a global minor mode for Emacs.  It
@@ -7875,14 +7874,13 @@ Idris.")
     (version "0.10.0")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append
-             "https://github.com/rmuslimov/browse-at-remote/archive/"
-             version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/rmuslimov/browse-at-remote.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "0ymslsp6i1naw25zckv25bf4aaq6qwkbkn95qyzlwg869l802686"))))
+        (base32 "0vhia7xmszcb3lxrb8wh93a3knjfzj48h8nhj4fh8zj1pjz6args"))))
     (build-system emacs-build-system)
     (propagated-inputs
      `(("emacs-f" ,emacs-f)
@@ -7965,7 +7963,7 @@ well as Github-style emojis like @code{:smile:}.  It provides a minor mode
        (uri (git-reference
              (url "https://github.com/ahyatt/emacs-websocket.git")
              (commit version)))
-       (file-name (string-append name "-" version "-checkout"))
+       (file-name (git-file-name name version))
        (sha256
         (base32
          "1dgrf7na6r6mmkknphzshlbd5fnzisg0qn0j7vfpa38wgsymaq52"))))
@@ -8096,25 +8094,28 @@ messaging service.")
    (version "2.1.0")
    (source
     (origin
-      (method url-fetch)
-      (uri (string-append
-            "https://github.com/szermatt/emacs-bash-completion/archive/v"
-            version ".tar.gz"))
-      (file-name (string-append name "-" version ".tar.gz"))
+      (method git-fetch)
+      (uri (git-reference
+            (url "https://github.com/szermatt/emacs-bash-completion.git")
+            (commit version)))
+      (file-name (git-file-name name version))
       (sha256
-       (base32
-        "1z0qck3v3ra6ivacn8n04w1v33a4xn01xx860761q31qzsv3sksq"))))
+       (base32 "1a1wxcqzh0javjmxwi3lng5i99xiylm8lm04kv4q1lh9bli6vmv0"))))
    (inputs `(("bash" ,bash)))
    (build-system emacs-build-system)
    (arguments
-     `(#:phases
-       (modify-phases %standard-phases
-         (add-before 'install 'configure
-           (lambda* (#:key inputs #:allow-other-keys)
-             (let ((bash (assoc-ref inputs "bash")))
-               (emacs-substitute-variables "bash-completion.el"
-                 ("bash-completion-prog" (string-append bash "/bin/bash"))))
-             #t)))))
+    `(#:phases
+      (modify-phases %standard-phases
+        (add-after 'unpack 'make-git-checkout-writable
+          (λ _
+            (for-each make-file-writable (find-files "."))
+            #t))
+        (add-before 'install 'configure
+          (lambda* (#:key inputs #:allow-other-keys)
+            (let ((bash (assoc-ref inputs "bash")))
+              (emacs-substitute-variables "bash-completion.el"
+                ("bash-completion-prog" (string-append bash "/bin/bash"))))
+            #t)))))
    (home-page "https://github.com/szermatt/emacs-bash-completion")
    (synopsis "Bash completion for the shell buffer")
    (description
@@ -8167,15 +8168,15 @@ in a generalized CSV (character-separated values) format.")
   (package
     (name "emacs-transmission")
     (version "0.12.1")
-    (source (origin
-              (method url-fetch)
-              (uri (string-append
-                    "https://github.com/holomorph/transmission/archive/"
-                    version ".tar.gz"))
-              (file-name (string-append name "-" version ".tar.gz"))
-              (sha256
-               (base32
-                "1rrlgn96gi1ljfwbwvlyyxbq75xzamlbdhq1bpyadxxmxcvlmk3n"))))
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/holomorph/transmission.git")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "0kvg2gawsgy440x1fsl2c4pkxwp3zirq9rzixanklk0ryijhd3ry"))))
     (build-system emacs-build-system)
     (home-page "https://github.com/holomorph/transmission")
     (synopsis "Emacs interface to a Transmission session")
@@ -8258,31 +8259,25 @@ for external literate programming tools for exporting, weaving and tangling.")
   (package
     (name "eless")
     (version "0.3")
-    (source (origin
-              (method url-fetch)
-              (uri (string-append
-                    "https://github.com/kaushalmodi/eless/archive/"
-                    "v" version ".tar.gz"))
-              (file-name (string-append name "-" version ".tar.gz"))
-              (sha256
-               (base32
-                "0gjnnhgw5xs1w3qfnkvwa2nv44gnxr8pkhx3c7qig45p8nh1461h"))))
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/kaushalmodi/eless.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "0jr7vhh4vw69llhi0fh9ljscljkszkj0acdxl04da5hvqv6pnqbb"))))
     (build-system trivial-build-system)
     (inputs
      `(("bash" ,bash)))
-    (native-inputs
-     `(("tar" ,tar)
-       ("gzip" ,gzip)))
     (arguments
      `(#:modules ((guix build utils))
        #:builder
        (begin
          (use-modules (guix build utils))
-         (setenv "PATH" (string-append
-                         (assoc-ref %build-inputs "tar") "/bin" ":"
-                         (assoc-ref %build-inputs "gzip") "/bin"))
-         (invoke "tar" "xvf" (assoc-ref %build-inputs "source"))
-         (chdir (string-append "eless" "-" ,version))
+         (copy-recursively (assoc-ref %build-inputs "source") "source")
+         (chdir "source")
          (substitute* "eless" (("/usr/bin/env bash")
                                (string-append (assoc-ref %build-inputs "bash")
                                               "/bin/bash")))
@@ -8318,14 +8313,13 @@ Feautures:
     (version "2.2.9")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append
-             "https://github.com/redguardtoo/evil-matchit/archive/"
-             version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/redguardtoo/evil-matchit.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "1i5a7szl0m3xnqyjq6zhg5j68x9fgf9ffxghj918c4brj4436sjb"))))
+        (base32 "12if45pxfndy3d7r4gd3zx4d3jk4d64fdmwkhc3y5zhqq9h9iy4c"))))
     (build-system emacs-build-system)
     (propagated-inputs
      `(("emacs-evil" ,emacs-evil)))
@@ -8342,14 +8336,13 @@ evil mode using @kbd{%}.  It is a port of @code{matchit} for Vim.")
     (version "0.4.0")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append
-             "https://github.com/expez/evil-smartparens/archive/"
-             version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/expez/evil-smartparens.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "1bwzdd3054d407d5j4m3njsbvmc9r8zzp33m32pj3b3irxrl68q0"))))
+        (base32 "1di4qz5fbrlwbg16c2j0m7y8zqfxw027qd7zqmc3rwk9znbhg7wl"))))
     (build-system emacs-build-system)
     (propagated-inputs
      `(("emacs-evil" ,emacs-evil)
@@ -8367,13 +8360,13 @@ emulates Vim features and provides Vim-like key bindings.")
     (version "0.1.4")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append "https://github.com/blorbx/evil-quickscope/archive/v"
-                           version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/blorbx/evil-quickscope.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "1r26a412mmar7vbf89zcifswiwpdg30mjzj32xdyqss57aqi83ma"))))
+        (base32 "1ja9ggj70wf0nmma4xnc1zdzg2crq9h1cv3cj7cgwjmllflgkfq7"))))
     (build-system emacs-build-system)
     (propagated-inputs
      `(("emacs-evil" ,emacs-evil)))
@@ -8396,14 +8389,13 @@ features and provides Vim-like key bindings.")
     (version "1.0")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append
-             "https://github.com/dbrock/bongo/archive/"
-             version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/dbrock/bongo.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "1pcsyyrvj7djjjwpaswd1i782hvqvlvs39cy9ns0k795si6xd64d"))))
+        (base32 "1q3ws2vn062dh7ci6jn2k2bcn7szh3ap64sgwkzdd6f1pas37fnr"))))
     (build-system emacs-build-system)
     (home-page "https://github.com/dbrock/bongo")
     (synopsis "Media player for Emacs")
@@ -8627,40 +8619,34 @@ Features:
     (version "0.1.0")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append "https://github.com/cute-jumper/epipe/archive/"
-                           version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/cute-jumper/epipe.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "05a036852g4j63k1mhvyfrcsgkl9lczayi7x61570ysw3cli5wp5"))))
+        (base32 "0lkisi1s7sn12nx8zh58qmsxwnk1rjwryj18wcbr148xqz3swg57"))))
     (build-system trivial-build-system)
     (inputs
      `(("bash" ,bash)
        ("perl" ,perl)))
-    (native-inputs
-     `(("tar" ,tar)
-       ("gzip" ,gzip)))
     (arguments
      `(#:modules
        ((guix build utils))
        #:builder
        (begin
          (use-modules (guix build utils))
-         ;; Extract source
-         (setenv "PATH" (string-append
-                         (assoc-ref %build-inputs "tar") "/bin" ":"
-                         (assoc-ref %build-inputs "gzip") "/bin"))
-         (invoke "tar" "xvf" (assoc-ref %build-inputs "source"))
-         (chdir (string-append ,name "-" ,version))
-         ;; Patch shebangs
+         ;; Extract source.
+         (copy-recursively (assoc-ref %build-inputs "source") "source")
+         (chdir "source")
+         ;; Patch shebangs.
          (substitute* "epipe"
            (("/usr/bin/env bash")
             (string-append (assoc-ref %build-inputs "bash") "/bin/bash")))
          (patch-shebang "epipe.pl"
                         (list (string-append (assoc-ref %build-inputs "perl")
                                              "/bin")))
-         ;; Installation
+         ;; Install.
          (for-each (lambda (file)
                      (install-file file (string-append %output "/bin")))
                    '("epipe" "epipe.pl"))
@@ -8677,14 +8663,13 @@ the pipeline, featuring the support for running @code{emacsclient}.")
     (version "0.03")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append
-             "https://github.com/syohex/emacs-hcl-mode/archive/"
-             version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/syohex/emacs-hcl-mode.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "0pvw74qpwh0znqzp6syp4wxjqs7dp1hbn5h7xfk97mff9l5d8k6x"))))
+        (base32 "0jqrgq15jz6pvx38pnwkizzfiih0d3nxqphyrc92nqpcyimg8b6g"))))
     (build-system emacs-build-system)
     (home-page "https://github.com/syohex/emacs-hcl-mode")
     (synopsis "Major mode for the Hashicorp Configuration Language")
@@ -8700,14 +8685,13 @@ highlighting and indentation support.")
     (version "0.06")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append
-             "https://github.com/syohex/emacs-terraform-mode/archive/"
-             version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/syohex/emacs-terraform-mode.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "0h9267ifdjmcin4sj8slxydbacx4bqicbvg8pa1qq2l72h9m5381"))))
+        (base32 "05hn8kskx9lcgn7bzgam99c629zlryir2pickwrqndacjrqpdykx"))))
     (build-system emacs-build-system)
     (propagated-inputs
      `(("emacs-hcl-mode" ,emacs-hcl-mode)))
@@ -8770,13 +8754,13 @@ directories of plain text notes, inspired by Notational Velocity.")
     (version "0.62")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append "https://github.com/syohex/emacs-anzu/archive/"
-                           version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/syohex/emacs-anzu.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "16cg3897x5znbmgk7sdy0qyd0fbic9dmmz0dchq2vz5z29yhg4cz"))))
+        (base32 "1lzvc0ihcbplir4hqfyxfqpsd78arz15gk92kmq4f8ggbkl37fan"))))
     (build-system emacs-build-system)
     (home-page "https://github.com/syohex/emacs-anzu")
     (synopsis "Show number of matches in mode-line while searching")
@@ -8872,15 +8856,15 @@ standard Unix password manager\").")
   (package
     (name "emacs-pass")
     (version "1.8")
-    (source (origin
-              (method url-fetch)
-              (uri (string-append
-                    "https://github.com/NicolasPetton/pass/archive/"
-                    version ".tar.gz"))
-              (sha256
-               (base32
-                "0aiz90gklk0cb8n4v1s3l0mx6pp2b7f4k2c0fjpihwmga13yklwn"))
-              (file-name (string-append name "-" version ".tar.gz"))))
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/NicolasPetton/pass.git")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "05h4hacv3yygyjcjj004qbyqjpkl4pyhwgp25gsz8mw5c66l70cx"))))
     (build-system emacs-build-system)
     (propagated-inputs
      `(("emacs-password-store" ,emacs-password-store)
@@ -8961,13 +8945,13 @@ match and total match information in the mode-line in various search modes.")
   (version "2.0.0")
   (source
     (origin
-      (method url-fetch)
-      (uri (string-append "https://github.com/skeeto/elisp-finalize/archive/"
-                          version ".tar.gz"))
-      (file-name (string-append name "-" version ".tar.gz"))
+      (method git-fetch)
+      (uri (git-reference
+            (url "https://github.com/skeeto/elisp-finalize.git")
+            (commit version)))
+      (file-name (git-file-name name version))
       (sha256
-        (base32
-         "077fycy3i5f0kjw5z3rhf4kld5lbk2idz690nkwhkz04vppk4q4x"))))
+        (base32 "1gvlm4i62af5jscwz0jccc8ra0grprxpg2rlq91d5nn8dn5lpy79"))))
   (build-system emacs-build-system)
   (propagated-inputs
     `(("emacs-cl-generic" ,emacs-cl-generic)))
@@ -9136,13 +9120,13 @@ Emacs.")
     (version "0.9")
     (source
      (origin
-       (method url-fetch)
-       (uri (string-append "https://github.com/purcell/elisp-slime-nav/archive/"
-                           version ".tar.gz"))
-       (file-name (string-append name "-" version ".tar.gz"))
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/purcell/elisp-slime-nav.git")
+             (commit version)))
+       (file-name (git-file-name name version))
        (sha256
-        (base32
-         "1vq7ym1q47p97gxrv45c9gm96d23xbp237vkmakikj6grngxjfb2"))))
+        (base32 "11vyy0bvzbs1h1kggikrvhd658j7c730w0pdp6qkm60rigvfi1ih"))))
     (build-system emacs-build-system)
     (home-page "https://github.com/purcell/elisp-slime-nav")
     (synopsis "Make @code{M-.} and @code{M-,} work for elisp like they do in SLIME")
@@ -9735,7 +9719,7 @@ functions provided by @file{subr.el}.")
          (uri (git-reference
                (url "https://github.com/re5et/itail.git")
                (commit commit)))
-         (file-name (string-append name "-" version "-checkout"))
+         (file-name (git-file-name name version))
          (sha256
           (base32
            "044nzxh1hq41faxw3lix0wy78vfz304pjcaa5a11dqfz7q3gx5cv"))))