* [bug#60549] [PATCH 2/5] gnu: Add emacs-citre.
@ 2023-01-04 12:46 tumashu
2023-01-07 0:00 ` bug#60549: " Nicolas Goaziou
0 siblings, 1 reply; 4+ messages in thread
From: tumashu @ 2023-01-04 12:46 UTC (permalink / raw)
To: 60549; +Cc: Feng Shu
From: Feng Shu <tumashu@163.com>
* gnu/packages/emacs-xyz.scm (emacs-citre): New variable.
---
gnu/packages/emacs-xyz.scm | 57 ++++++++++++++++++++++++++++++++++++++
1 file changed, 57 insertions(+)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index d4f0dc82a0..507ba3be61 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -34104,6 +34104,63 @@ (define-public emacs-global-tags
project.el and xref.el.")
(license license:gpl3+))))
+(define-public emacs-citre
+ (package
+ (name "emacs-citre")
+ (version "0.3.1")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/universal-ctags/citre/")
+ (commit (string-append "v" version))))
+ (sha256
+ (base32 "168z6yidh2nxkmdlx9cqdzzb7achxdipnbk5pj9787m9bp1sdpkd"))
+ (file-name (git-file-name name version))))
+ (build-system emacs-build-system)
+ (arguments
+ (list
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'unpack 'patch-citre-ctags-program
+ (lambda* (#:key inputs #:allow-other-keys)
+ (emacs-substitute-sexps "citre-ctags.el"
+ ("defcustom citre-ctags-program"
+ (string-append (assoc-ref inputs "universal-ctags")
+ "/bin/ctags")))))
+ (add-after 'unpack 'patch-citre-readtags-program
+ (lambda* (#:key inputs #:allow-other-keys)
+ (emacs-substitute-sexps "citre-readtags.el"
+ ("defcustom citre-readtags-program"
+ (string-append (assoc-ref inputs "universal-ctags")
+ "/bin/readtags")))))
+ (add-after 'unpack 'patch-citre-gtags-program
+ (lambda* (#:key inputs #:allow-other-keys)
+ (emacs-substitute-sexps "citre-global.el"
+ ("defcustom citre-gtags-program"
+ (string-append (assoc-ref inputs "global")
+ "/bin/gtags")))))
+ (add-after 'unpack 'patch-citre-global-program
+ (lambda* (#:key inputs #:allow-other-keys)
+ (emacs-substitute-sexps "citre-global.el"
+ ("defcustom citre-global-program"
+ (string-append (assoc-ref inputs "global")
+ "/bin/global"))))))))
+ (inputs (list global universal-ctags))
+ (home-page "https://github.com/universal-ctags/citre")
+ (synopsis "Ctags IDE on the True Editor")
+ (description
+ "Citre is an advanced Ctags (or actually, readtags) frontend for
+Emacs. It offers:
+
+@itemize
+@item completion-at-point, xref and imenu integration.
+@item citre-jump: A completing-read UI for jumping to definition.
+@item citre-peek: A powerful code reading tool that lets you go down the
+rabbit hole without leaving current buffer.
+@end itemize\n")
+ (license license:gpl3+)))
+
(define-public emacs-seq
(package
(name "emacs-seq")
--
2.38.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* bug#60549: [PATCH 2/5] gnu: Add emacs-citre.
2023-01-04 12:46 [bug#60549] [PATCH 2/5] gnu: Add emacs-citre tumashu
@ 2023-01-07 0:00 ` Nicolas Goaziou
2023-01-07 7:16 ` [bug#60549] " Feng Shu
0 siblings, 1 reply; 4+ messages in thread
From: Nicolas Goaziou @ 2023-01-07 0:00 UTC (permalink / raw)
To: tumashu; +Cc: 60549-done
Hello,
tumashu@163.com writes:
> * gnu/packages/emacs-xyz.scm (emacs-citre): New variable.
Applied, with the changes detailed below. Thank you.
> + #~(modify-phases %standard-phases
> + (add-after 'unpack 'patch-citre-ctags-program
> + (lambda* (#:key inputs #:allow-other-keys)
> + (emacs-substitute-sexps "citre-ctags.el"
> + ("defcustom citre-ctags-program"
> + (string-append (assoc-ref inputs "universal-ctags")
> + "/bin/ctags")))))
> + (add-after 'unpack 'patch-citre-readtags-program
> + (lambda* (#:key inputs #:allow-other-keys)
> + (emacs-substitute-sexps "citre-readtags.el"
> + ("defcustom citre-readtags-program"
> + (string-append (assoc-ref inputs "universal-ctags")
> + "/bin/readtags")))))
> + (add-after 'unpack 'patch-citre-gtags-program
> + (lambda* (#:key inputs #:allow-other-keys)
> + (emacs-substitute-sexps "citre-global.el"
> + ("defcustom citre-gtags-program"
> + (string-append (assoc-ref inputs "global")
> + "/bin/gtags")))))
> + (add-after 'unpack 'patch-citre-global-program
> + (lambda* (#:key inputs #:allow-other-keys)
> + (emacs-substitute-sexps "citre-global.el"
> + ("defcustom citre-global-program"
> + (string-append (assoc-ref inputs "global")
> + "/bin/global"))))))))
I merged everything into a single phase and used more specific
`emacs-substitute-variables' instead of `emacs-substitute-sexps'.
> + (inputs (list global universal-ctags))
> + (home-page "https://github.com/universal-ctags/citre")
> + (synopsis "Ctags IDE on the True Editor")
> + (description
> + "Citre is an advanced Ctags (or actually, readtags) frontend for
> +Emacs. It offers:
> +
> +@itemize
> +@item completion-at-point, xref and imenu integration.
> +@item citre-jump: A completing-read UI for jumping to definition.
> +@item citre-peek: A powerful code reading tool that lets you go down the
> +rabbit hole without leaving current buffer.
> +@end itemize\n")
I reworded the description.
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 4+ messages in thread
* [bug#60549] [PATCH 2/5] gnu: Add emacs-citre.
2023-01-07 0:00 ` bug#60549: " Nicolas Goaziou
@ 2023-01-07 7:16 ` Feng Shu
2023-01-07 11:11 ` Nicolas Goaziou
0 siblings, 1 reply; 4+ messages in thread
From: Feng Shu @ 2023-01-07 7:16 UTC (permalink / raw)
To: Nicolas Goaziou; +Cc: 60549-done
[-- Attachment #1: Type: text/plain, Size: 131 bytes --]
Nicolas Goaziou <mail@nicolasgoaziou.fr> writes:
Hello:
emacs-citre now get the wrong ctags path, for emacs has ctags too. :-)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-emacs-cire-Search-proper-ctags-program.patch --]
[-- Type: text/x-patch, Size: 1394 bytes --]
From 9b69ed1524cbe3aa3cb75b44fcb7453b43ee06c2 Mon Sep 17 00:00:00 2001
From: Feng Shu <tumashu@163.com>
Date: Sat, 7 Jan 2023 15:07:14 +0800
Subject: [PATCH] gnu: emacs-cire: Search proper ctags program
* gnu/packages/emacs-xyz.scm (emacs-citre) [arguments]<#:phases>: Do not use
search-input-file to search ctags, for it will get ctags of emacs-minimal
instead of universal-ctags.
---
gnu/packages/emacs-xyz.scm | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index b6024925ec..4e7aa568ea 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -34170,7 +34170,11 @@ (define-public emacs-citre
(lambda* (#:key inputs #:allow-other-keys)
(emacs-substitute-variables "citre-ctags.el"
("citre-ctags-program"
- (search-input-file inputs "/bin/ctags")))
+ ;; NOTE: Do not use search-input-file in this place, for it
+ ;; will get ctags of emacs-minimal instead of
+ ;; universal-ctags.
+ (string-append (assoc-ref inputs "universal-ctags")
+ "/bin/ctags")))
(emacs-substitute-variables "citre-readtags.el"
("citre-readtags-program"
(search-input-file inputs "/bin/readtags")))
--
2.38.1
[-- Attachment #3: Type: text/plain, Size: 2394 bytes --]
> Hello,
>
> tumashu@163.com writes:
>
>> * gnu/packages/emacs-xyz.scm (emacs-citre): New variable.
>
> Applied, with the changes detailed below. Thank you.
>
>> + #~(modify-phases %standard-phases
>> + (add-after 'unpack 'patch-citre-ctags-program
>> + (lambda* (#:key inputs #:allow-other-keys)
>> + (emacs-substitute-sexps "citre-ctags.el"
>> + ("defcustom citre-ctags-program"
>> + (string-append (assoc-ref inputs "universal-ctags")
>> + "/bin/ctags")))))
>> + (add-after 'unpack 'patch-citre-readtags-program
>> + (lambda* (#:key inputs #:allow-other-keys)
>> + (emacs-substitute-sexps "citre-readtags.el"
>> + ("defcustom citre-readtags-program"
>> + (string-append (assoc-ref inputs "universal-ctags")
>> + "/bin/readtags")))))
>> + (add-after 'unpack 'patch-citre-gtags-program
>> + (lambda* (#:key inputs #:allow-other-keys)
>> + (emacs-substitute-sexps "citre-global.el"
>> + ("defcustom citre-gtags-program"
>> + (string-append (assoc-ref inputs "global")
>> + "/bin/gtags")))))
>> + (add-after 'unpack 'patch-citre-global-program
>> + (lambda* (#:key inputs #:allow-other-keys)
>> + (emacs-substitute-sexps "citre-global.el"
>> + ("defcustom citre-global-program"
>> + (string-append (assoc-ref inputs "global")
>> + "/bin/global"))))))))
>
> I merged everything into a single phase and used more specific
> `emacs-substitute-variables' instead of `emacs-substitute-sexps'.
>
>> + (inputs (list global universal-ctags))
>> + (home-page "https://github.com/universal-ctags/citre")> + (synopsis "Ctags IDE on the True Editor")
>> + (description
>> + "Citre is an advanced Ctags (or actually, readtags) frontend for
>> +Emacs. It offers:
>> +
>> +@itemize
>> +@item completion-at-point, xref and imenu integration.
>> +@item citre-jump: A completing-read UI for jumping to definition.
>> +@item citre-peek: A powerful code reading tool that lets you go down the
>> +rabbit hole without leaving current buffer.
>> +@end itemize\n")
>
> I reworded the description.
>
> Regards,
--
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [bug#60549] [PATCH 2/5] gnu: Add emacs-citre.
2023-01-07 7:16 ` [bug#60549] " Feng Shu
@ 2023-01-07 11:11 ` Nicolas Goaziou
0 siblings, 0 replies; 4+ messages in thread
From: Nicolas Goaziou @ 2023-01-07 11:11 UTC (permalink / raw)
To: Feng Shu; +Cc: 60549-done
Hello,
Feng Shu <tumashu@163.com> writes:
> emacs-citre now get the wrong ctags path, for emacs has ctags too. :-)
Indeed! I applied your patch, but used `this-package-input' instead of
(assoc-ref …). Thank you.
Regards,
--
Nicolas Goaziou
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-01-07 11:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-04 12:46 [bug#60549] [PATCH 2/5] gnu: Add emacs-citre tumashu
2023-01-07 0:00 ` bug#60549: " Nicolas Goaziou
2023-01-07 7:16 ` [bug#60549] " Feng Shu
2023-01-07 11:11 ` Nicolas Goaziou
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).