From: Felix Gruber <felgru@posteo.net>
To: 51533@debbugs.gnu.org
Cc: Felix Gruber <felgru@posteo.net>
Subject: [bug#51533] [PATCH] gnu: Add python-codespell.
Date: Sun, 31 Oct 2021 21:49:27 +0000 [thread overview]
Message-ID: <20211031214927.3349-1-felgru@posteo.net> (raw)
* gnu/packages/python-xyz.scm (python-codespell): New variable.
---
gnu/packages/python-xyz.scm | 47 +++++++++++++++++++++++++++++++++++++
1 file changed, 47 insertions(+)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index f12cca9757..fb49c4291e 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -14228,6 +14228,53 @@ checking library.")
,python2-backport-ssl-match-hostname)
,@(package-propagated-inputs whoosh))))))
+(define-public python-codespell
+ (package
+ (name "python-codespell")
+ (version "2.1.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "codespell" version))
+ (sha256
+ (base32 "1r9y714cz8m894rxp7pyvicr1lw2iid24vz6fxbl5wzy8ibgxlqr"))))
+ (build-system python-build-system)
+ (inputs
+ `(("python-chardet" ,python-chardet)))
+ (native-inputs
+ `(("python-check-manifest" ,python-check-manifest)
+ ("python-flake8" ,python-flake8)
+ ("python-pytest" ,python-pytest)
+ ("python-pytest-cov" ,python-pytest-cov)
+ ("python-pytest-dependency" ,python-pytest-dependency)))
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key outputs tests? #:allow-other-keys)
+ (when tests?
+ ;; Make installed executable available for running the tests.
+ (setenv "PATH"
+ (string-append (assoc-ref outputs "out") "/bin"
+ ":" (getenv "PATH")))
+ (invoke "pytest" "-vv")))))))
+ (home-page "https://github.com/codespell-project/codespell/")
+ (synopsis "Spellchecker for code")
+ (description "Codespell fixes common misspellings in text files.
+It's designed primarily for checking misspelled words in source code,
+but it can be used with other files as well. It does not check for word
+membership in a complete dictionary, but instead looks for a set of
+common misspellings. Therefore it should catch errors like \"adn\", but
+it will not catch \"adnasdfasdf\". This also means it shouldn't
+generate false-positives when you use a niche term it doesn't know
+about.")
+ (license
+ (list
+ ; for codespell and codespell_lib
+ license:gpl2
+ ; for dictionary*.txt
+ license:cc-by-sa3.0))))
+
(define-public python-pathlib
(package
(name "python-pathlib")
--
2.30.2
next reply other threads:[~2021-10-31 22:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-31 21:49 Felix Gruber [this message]
2021-12-01 15:19 ` bug#51533: [PATCH] gnu: Add python-codespell Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211031214927.3349-1-felgru@posteo.net \
--to=felgru@posteo.net \
--cc=51533@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.