[PATCH 0/3] gnu: add emacs-flymake-proselint and dependencies

DoneSubmitted by Jai Vetrivelan.
Details
2 participants
  • Jai Vetrivelan
  • Ludovic Courtès
Owner
unassigned
Severity
normal
J
J
Jai Vetrivelan wrote on 14 Apr 08:55 +0200
(address . guix-patches@gnu.org)
871qy0yx00.fsf@gmail.com
Hello, this patch series adds the flymake-proselint package which
depends on proselint. Proselint requires python-click <9.0.0, >=8.0.0,
so I've added version 8 of python-click.

Builds successfully on Guix System x86_64. Feedback Welcome.

Jai Vetrivelan (3):
gnu: Add python-click-8.
gnu: add python-proselint.
gnu: Add emacs-flymake-proselint.

gnu/packages/emacs-xyz.scm | 35 ++++++++++++++++++++++++++++++++
gnu/packages/python-xyz.scm | 40 +++++++++++++++++++++++++++++++++++++
2 files changed, 75 insertions(+)


base-commit: 5743d505834a8b13778da2c969ea4e15bb7a3a75
--
2.34.0
J
J
Jai Vetrivelan wrote on 14 Apr 09:00 +0200
[PATCH 1/3] gnu: Add python-click-8.
(address . 54924@debbugs.gnu.org)(name . Jai Vetrivelan)(address . jaivetrivelan@gmail.com)
20220414070030.5917-1-jaivetrivelan@gmail.com
* gnu/packages/python-xyz.scm (python-click-8): New variable.
---
gnu/packages/python-xyz.scm | 12 ++++++++++++
1 file changed, 12 insertions(+)

Toggle diff (25 lines)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 36e4fe5898..f98dd29083 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -3508,6 +3508,18 @@ (define-public python-click-5
         (base32 "0njsm0wn31l21bi118g5825ma5sa3rwn7v2x4wjd7yiiahkri337"))))
     (arguments `())))
 
+(define-public python-click-8
+  (package (inherit python-click)
+    (name "python-click")
+    (version "8.1.2")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "click" version))
+       (sha256
+        (base32 "0whs38a2i0561kwbgigs6vic9r0a1887m2v1aw3rmv6r2kz0g5s7"))))
+    (arguments `())))
+
 (define-public python-cligj
   (package
     (name "python-cligj")
-- 
2.34.0
J
J
Jai Vetrivelan wrote on 14 Apr 09:00 +0200
[PATCH 2/3] gnu: add python-proselint.
(address . 54924@debbugs.gnu.org)(name . Jai Vetrivelan)(address . jaivetrivelan@gmail.com)
20220414070030.5917-2-jaivetrivelan@gmail.com
* gnu/packages/python-xyz.scm (python-proselint): New variable.
---
gnu/packages/python-xyz.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)

Toggle diff (48 lines)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index f98dd29083..cde4abbcf7 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -118,6 +118,7 @@
 ;;; Copyright © 2022 Aleksandr Vityazev <avityazev@posteo.org>
 ;;; Copyright © 2022 Evgeny Pisemsky <evgeny@pisemsky.com>
 ;;; Copyright © 2022 drozdov <drozdov@portalenergy.tech>
+;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -17196,6 +17197,33 @@ (define-public python-prompt-toolkit
     (license license:bsd-3)
     (properties `((python2-variant . ,(delay python-prompt-toolkit-2))))))
 
+(define-public python-proselint
+  (package
+   (name "python-proselint")
+   (version "0.13.0")
+   (source
+    (origin
+      (method url-fetch)
+      (uri (pypi-uri "proselint" version))
+      (sha256
+       (base32
+        "0n1ahnq2mkgvh94g05xhc3l1fs3hh0ycskqlqivhhfdaq8ybdlkx"))))
+   (build-system python-build-system)
+   (arguments
+    `(#:tests? #f
+      #:phases
+      (modify-phases %standard-phases
+        (add-after 'unpack 'set-home-directory
+          (lambda _ (setenv "HOME" "/tmp") #t)))))
+   (propagated-inputs
+    (list python-click-8 python-future python-six))
+   (home-page
+    "http://github.com/amperser/proselint")
+   (synopsis "Linter for prose")
+   (description "@code{python-proselint} is a linter for English prose, that scans through a
+file and detects issues.")
+   (license license:bsd-3)))
+
 (define-public python-prompt-toolkit-2
   (package (inherit python-prompt-toolkit)
     (name "python-prompt-toolkit")
-- 
2.34.0
J
J
Jai Vetrivelan wrote on 14 Apr 09:00 +0200
[PATCH 3/3] gnu: Add emacs-flymake-proselint.
(address . 54924@debbugs.gnu.org)(name . Jai Vetrivelan)(address . jaivetrivelan@gmail.com)
20220414070030.5917-3-jaivetrivelan@gmail.com
* gnu/packages/emacs-xyz.scm (emacs-flymake-proselint): New variable.
---
gnu/packages/emacs-xyz.scm | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)

Toggle diff (48 lines)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 005f34e569..bc96813754 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -6120,6 +6120,41 @@ (define-public emacs-flycheck-package
 files which are intended to be packages.")
     (license license:gpl3+)))
 
+(define-public emacs-flymake-proselint
+  (let ((commit "6a99865c7ac6474b8c5d1f9a1ae2384667f06d36")
+        (revision "0"))
+   (package
+     (name "emacs-flymake-proselint")
+     (version (git-version "0.2.3" revision commit))
+     (source (origin
+               (method git-fetch)
+               (uri (git-reference
+                     (url "https://git.sr.ht/~manuel-uberti/flycheck-proselint")
+                     (commit commit)))
+               (file-name (git-file-name name version))
+               (sha256
+                (base32
+                 "028ilp9h22rlawlh5ydiykvi8pryyknwi019sjyxkk2h0fza9jan"))))
+     (build-system emacs-build-system)
+     (arguments
+      (list
+       #:phases
+       #~(modify-phases %standard-phases
+           (add-after 'unpack 'patch-exec-paths
+             (lambda* (#:key inputs #:allow-other-keys)
+               (substitute* "flymake-proselint.el"
+                 (("\"proselint\"")
+                  (string-append
+                   "\"" (search-input-file inputs "/bin/proselint") "\""))))))))
+     (propagated-inputs
+      (list emacs-flycheck))
+     (inputs
+      (list python-proselint))
+     (home-page "https://git.sr.ht/~manuel-uberti/flycheck-proselint")
+     (synopsis "Flymake backend for @code{proselint}")
+     (description "This package adds support for @code{proselint} in Flymake.")
+     (license license:gpl3+))))
+
 (define-public emacs-elisp-demos
   (package
     (name "emacs-elisp-demos")
-- 
2.34.0
J
J
Jai Vetrivelan wrote on 14 Apr 10:20 +0200
control message for #54924
(address . control@debbugs.gnu.org)
87pmlkxehz.fsf@gmail.com
retitle 54924 [PATCH 0/3] gnu: add emacs-flymake-proselint and dependencies
thanks

--
Jai Vetrivelan
L
L
Ludovic Courtès wrote on 9 May 00:02 +0200
Re: bug#54924: [PATCH 0/3] gnu: add emacs-flymake-proselint and dependencies
(name . Jai Vetrivelan)(address . jaivetrivelan@gmail.com)(address . 54924-done@debbugs.gnu.org)
87czgnvg2c.fsf@gnu.org
Hi,

Jai Vetrivelan <jaivetrivelan@gmail.com> skribis:

Toggle quote (4 lines)
> gnu: Add python-click-8.
> gnu: add python-proselint.
> gnu: Add emacs-flymake-proselint.

Applied, thanks!

Ludo’.
Closed
?
Your comment

This issue is archived.

To comment on this conversation send email to 54924@debbugs.gnu.org