diff mbox series

[bug#42525,2/2] gnu: Add emacs-major-mode-hydra.

Message ID 87r1szsknr.fsf@odyssey.lafreniere.xyz
State New
Headers show
Series None | expand

Checks

Context Check Description
cbaines/applying patch fail View Laminar job

Commit Message

Joseph LaFreniere July 25, 2020, 3:02 p.m. UTC
Thank you for the reviews, Oleg.  :)

Oleg Pykhalov <go.wigust@gmail.com> writes:
> Joseph LaFreniere <joseph@lafreniere.xyz> writes:
>
>> Patch file is attached.  Similar to the first patch in this 
>> series, `guix
>> lint` reports "the source file name should contain the package 
>> name".
>
> Yes, because emacs-major-mode-hydra inherits emacs-pretty-hydra.

Fixed in the updated patch for emacs-pretty-hydra.

> Does emacs-major-mode-hydra is useful without emacs-pretty-hydra 
> and
> vice versa?
>
> I guess not, in that case we could just have emacs-pretty-hydra
> containing '*.el' for both.

Yes, emacs-pretty-hydra is useful independently of 
emacs-major-mode-hydra.  The descriptions in the initial patches 
were written a long time ago and were misleading.  I apologize for 
the confusion.

> Could you extend the synopsis little bit? ;-)

Missed this comment in the updated patch for emacs-pretty-hydra 
that I just sent.  I will revisit it following this mail.  Is the 
synopsis for this recipe (emacs-major-mode-hyra) suitable?

--
Joseph LaFreniere
diff mbox series

Patch

From 01cec639c237f582a9e4ecbfec1f483009bbba36 Mon Sep 17 00:00:00 2001
From: Joseph LaFreniere <joseph@lafreniere.xyz>
Date: Sat, 18 Jul 2020 12:50:22 -0500
Subject: [PATCH 2/2] gnu: Add emacs-major-mode-hydra.

* gnu/packages/emacs-xyz.scm (emacs-major-mode-hydra): New variable.
---
 gnu/packages/emacs-xyz.scm | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index c11959dbe2..195586ca71 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -676,6 +676,25 @@  process, passing on the arguments as command line arguments.")
 hydras with one column per group of heads.")
     (license license:gpl3+)))
 
+(define-public emacs-major-mode-hydra
+  (package
+    (inherit emacs-pretty-hydra)
+    (name "emacs-major-mode-hydra")
+    (propagated-inputs
+     `(("emacs-dash" ,emacs-dash)
+       ("emacs-pretty-hydra" ,emacs-pretty-hydra)))
+    (native-inputs
+     `(("emacs-ert-runner" ,emacs-ert-runner)
+       ("emacs-use-package" ,emacs-use-package) ))
+    (arguments
+     `(#:exclude (cons "^pretty-hydra\\.el$" %default-exclude)
+       #:tests? #t
+       #:test-command '("ert-runner")))
+    (synopsis "Major mode keybindings managed by Hydra")
+    (description
+     "This package offers a hydra-based method of managing major mode-specific
+key bindings.")))
+
 (define-public emacs-minions
   (package
     (name "emacs-minions")
-- 
2.27.0