all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#74100] [PATCH] gnu: Add emacs-visual-replace.
@ 2024-10-30  3:14 Suhail Singh
  2024-11-03 20:58 ` Nicolas Graves via Guix-patches via
  0 siblings, 1 reply; 4+ messages in thread
From: Suhail Singh @ 2024-10-30  3:14 UTC (permalink / raw)
  To: 74100; +Cc: Andrew Tropin, Katherine Cox-Buday, Liliana Marie Prikler


* gnu/packages/emacs-xyz.scm (emacs-visual-replace): New variable.

Change-Id: I7c579785ed6b0e2989d16fb0b100e9860e8f38b9
---
 gnu/packages/emacs-xyz.scm | 62 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 62 insertions(+)

diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 488b4cb5d7..367cafdd85 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -16175,6 +16175,68 @@ (define-public emacs-visual-fill-column
 window edge.")
     (license license:gpl3+)))
 
+(define-public emacs-visual-replace
+  (package
+    (name "emacs-visual-replace")
+    ;; XXX: when updating version, please ensure substitution in install-info
+    ;; phase is still accurate.
+    (version "1.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/szermatt/visual-replace")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "085dg77wpa371i8lvsl9ckm09yfjvqwym6wrs8lxfvih5jd7mm1b"))))
+    (build-system emacs-build-system)
+    (arguments
+     (list
+      #:tests? #t
+      #:phases #~(modify-phases %standard-phases
+                   (add-before 'check 'add-test-dir-to-emacs-load-path
+                     (lambda _
+                       (setenv "EMACSLOADPATH"
+                               (string-append (getcwd) "/test:"
+                                              (getenv "EMACSLOADPATH")))))
+                   (add-after 'install 'install-info
+                     (lambda* (#:key outputs #:allow-other-keys)
+                       (let* ((out (assoc-ref outputs "out"))
+                              (info-dir (string-append out "/share/info")))
+                         (invoke "eldev" "build" "--force"
+                                 "visual-replace.texi")
+                         (with-directory-excursion "docs/build/texinfo"
+                           (substitute* "visual-replace.texi"
+                             ;; XXX: Undo damage caused by sphinx-build
+                             (("visual-replace ([^,]+), Jan 01, 1970" _ ver)
+                              (string-append "visual-replace " ver))
+                             (("@copyright\\{\\} 2020-1970")
+                              "@copyright{} 2020-2024"))
+                           (invoke "make" "info")
+                           (install-file "./visual-replace.info" info-dir)
+                           (copy-recursively "./visual-replace-figures"
+                                             (string-append info-dir
+                                              "/visual-replace-figures")))))))
+      #:test-command #~(list "eldev" "--use-emacsloadpath" "-dtTC" "test")))
+    (native-inputs (list emacs-eldev python-sphinx texinfo))
+    (home-page "https://github.com/szermatt/visual-replace")
+    (synopsis
+     "Alternate interface for @code{replace-string} and @code{query-replace}")
+    (description
+     "@code{visual-replace} provides an alternate interface for search and
+replacement commands that supports previews.  The interface also allows one to
+edit both the query-text and its replacement in the same minibuffer prompt.
+The interface covers the following commands:
+
+@enumerate
+@item @code{replace-string}
+@item @code{replace-regexp}
+@item @code{query-replace}
+@item @code{query-replace-regexp}
+@end enumerate")
+    (license license:gpl3+)))
+
 (define-public emacs-writeroom
   (package
     (name "emacs-writeroom")

base-commit: a9c33e9f688fce88aed610ab04c650efb71b4ce6
-- 
2.47.0





^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#74100] [PATCH] gnu: Add emacs-visual-replace.
  2024-10-30  3:14 [bug#74100] [PATCH] gnu: Add emacs-visual-replace Suhail Singh
@ 2024-11-03 20:58 ` Nicolas Graves via Guix-patches via
  2024-11-03 22:45   ` Suhail Singh
  0 siblings, 1 reply; 4+ messages in thread
From: Nicolas Graves via Guix-patches via @ 2024-11-03 20:58 UTC (permalink / raw)
  To: Suhail Singh, 74100
  Cc: Katherine Cox-Buday, Liliana Marie Prikler, Andrew Tropin


Hi Suhail,

Is your previous emacs-eldev update a requirement for this patch?

-- 
Best regards,
Nicolas Graves




^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#74100] [PATCH] gnu: Add emacs-visual-replace.
  2024-11-03 20:58 ` Nicolas Graves via Guix-patches via
@ 2024-11-03 22:45   ` Suhail Singh
  2024-11-15  7:42     ` bug#74100: " Liliana Marie Prikler
  0 siblings, 1 reply; 4+ messages in thread
From: Suhail Singh @ 2024-11-03 22:45 UTC (permalink / raw)
  To: Nicolas Graves
  Cc: Katherine Cox-Buday, Liliana Marie Prikler, Andrew Tropin,
	Suhail Singh, 74100

Nicolas Graves <ngraves@ngraves.fr> writes:

> Is your previous emacs-eldev update a requirement for this patch?

No, they are independent.  Thank you for taking a look.

-- 
Suhail




^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#74100: [PATCH] gnu: Add emacs-visual-replace.
  2024-11-03 22:45   ` Suhail Singh
@ 2024-11-15  7:42     ` Liliana Marie Prikler
  0 siblings, 0 replies; 4+ messages in thread
From: Liliana Marie Prikler @ 2024-11-15  7:42 UTC (permalink / raw)
  To: Suhail Singh, Nicolas Graves
  Cc: Katherine Cox-Buday, Andrew Tropin, 74100-done

Am Sonntag, dem 03.11.2024 um 17:45 -0500 schrieb Suhail Singh:
> Nicolas Graves <ngraves@ngraves.fr> writes:
> 
> > Is your previous emacs-eldev update a requirement for this patch?
> 
> No, they are independent.  Thank you for taking a look.
I think this got lost.  Pushed now :)

Cheers




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-11-15  7:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-30  3:14 [bug#74100] [PATCH] gnu: Add emacs-visual-replace Suhail Singh
2024-11-03 20:58 ` Nicolas Graves via Guix-patches via
2024-11-03 22:45   ` Suhail Singh
2024-11-15  7:42     ` bug#74100: " Liliana Marie Prikler

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.