* [bug#46616] [PATCH] gnu: Add python-tldr.
@ 2021-02-18 14:06 Tanguy Le Carrour
2021-05-23 21:15 ` Vinicius Monego
2021-06-06 14:16 ` [bug#46616] [PATCH v2] " Tanguy Le Carrour
0 siblings, 2 replies; 6+ messages in thread
From: Tanguy Le Carrour @ 2021-02-18 14:06 UTC (permalink / raw)
To: 46616; +Cc: Tanguy Le Carrour
* gnu/packages/python-xyz.scm (python-tldr): New variable.
---
gnu/packages/python-xyz.scm | 28 +++++++++++++++++++++++++++-
1 file changed, 27 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index a504bb521b..b315d5f634 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -66,7 +66,7 @@
;;; Copyright © 2019 Jacob MacDonald <jaccarmac@gmail.com>
;;; Copyright © 2019, 2020 Giacomo Leidi <goodoldpaul@autistici.org>
;;; Copyright © 2019 Wiktor Żelazny <wzelazny@vurv.cz>
-;;; Copyright © 2019, 2020 Tanguy Le Carrour <tanguy@bioneland.org>
+;;; Copyright © 2019, 2020, 2021 Tanguy Le Carrour <tanguy@bioneland.org>
;;; Copyright © 2019 Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de>
;;; Copyright © 2020 Riku Viitanen <riku.viitanen@protonmail.com>
;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
@@ -19267,6 +19267,32 @@ Public Suffix List's private domains as well.")
(define-public python2-tldextract
(package-with-python2 python-tldextract))
+(define-public python-tldr
+ (package
+ (name "python-tldr")
+ (version "1.2.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (pypi-uri "tldr" version))
+ (sha256
+ (base32
+ "00h43xjrzrayy1gysvmql5kfabk2d8xraih68d41616brdvb1xvf"))))
+ (build-system python-build-system)
+ (native-inputs
+ `(("python-pytest" ,python-pytest)
+ ("python-pytest-runner" ,python-pytest-runner)))
+ (propagated-inputs
+ `(("python-argcomplete" ,python-argcomplete)
+ ("python-colorama" ,python-colorama)
+ ("python-termcolor" ,python-termcolor)))
+ (home-page "https://github.com/tldr-pages/tldr-python-client")
+ (synopsis "Python command-line client for tldr pages")
+ (description "This package provides the `tldr' command allowing users
+to view `tldr' pages from a shell. The `tldr' pages are a community effort
+to simplify the man pages with practical examples.")
+ (license license:expat))) ; MIT license
+
(define-public python-nodeenv
(package
(name "python-nodeenv")
--
2.30.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [bug#46616] [PATCH] gnu: Add python-tldr.
2021-02-18 14:06 [bug#46616] [PATCH] gnu: Add python-tldr Tanguy Le Carrour
@ 2021-05-23 21:15 ` Vinicius Monego
2021-06-06 14:14 ` Tanguy LE CARROUR
2021-06-06 14:16 ` [bug#46616] [PATCH v2] " Tanguy Le Carrour
1 sibling, 1 reply; 6+ messages in thread
From: Vinicius Monego @ 2021-05-23 21:15 UTC (permalink / raw)
To: Tanguy Le Carrour; +Cc: 46616
Hi,
Em qui, 2021-02-18 às 15:06 +0100, Tanguy Le Carrour escreveu:
> * gnu/packages/python-xyz.scm (python-tldr): New variable.
> ---
> gnu/packages/python-xyz.scm | 28 +++++++++++++++++++++++++++-
[...]
> +(define-public python-tldr
> + (package
> + (name "python-tldr")
I noticed that this program is a command line tool. It should be named
'tldr' only and be moved to another file. Perhaps to man.scm?
> + (source
> + (origin
> + (method url-fetch)
> + (uri (pypi-uri "tldr" version))
> + (sha256
> + (base32
> + "00h43xjrzrayy1gysvmql5kfabk2d8xraih68d41616brdvb1xvf"))))
> + (build-system python-build-system)
> + (native-inputs
> + `(("python-pytest" ,python-pytest)
> + ("python-pytest-runner" ,python-pytest-runner)))
The tests for this one are not distributed in the PyPI release. Could
you source from the homepage instead?
There is one test that tries to open a network connection, it will have
to be skipped.
> + (propagated-inputs
> + `(("python-argcomplete" ,python-argcomplete)
> + ("python-colorama" ,python-colorama)
> + ("python-termcolor" ,python-termcolor)))
If it is only a command line tool, inputs should be normal inputs here.
> + (description "This package provides the `tldr' command allowing
> users
> +to view `tldr' pages from a shell. The `tldr' pages are a community
> effort
> +to simplify the man pages with practical examples.")
The linter made this complaint for the description: "use @code or
similar ornament instead of quotes".
LGTM otherwise.
Could you make these changes and send a v2 with version 1.2.1?
Vinicius
^ permalink raw reply [flat|nested] 6+ messages in thread
* [bug#46616] [PATCH] gnu: Add python-tldr.
2021-05-23 21:15 ` Vinicius Monego
@ 2021-06-06 14:14 ` Tanguy LE CARROUR
0 siblings, 0 replies; 6+ messages in thread
From: Tanguy LE CARROUR @ 2021-06-06 14:14 UTC (permalink / raw)
To: Vinicius Monego; +Cc: 46616
Hi Vinicius,
Thanks for reviewing this patch, and sorry for the late answer!
Excerpts from Vinicius Monego's message of May 23, 2021 11:15 pm:
> Em qui, 2021-02-18 às 15:06 +0100, Tanguy Le Carrour escreveu:
>> * gnu/packages/python-xyz.scm (python-tldr): New variable.
>> ---
>> gnu/packages/python-xyz.scm | 28 +++++++++++++++++++++++++++-
>
> [...]
>
>> +(define-public python-tldr
>> + (package
>> + (name "python-tldr")
>
> I noticed that this program is a command line tool. It should be named
> 'tldr' only and be moved to another file. Perhaps to man.scm?
Your suggestions make sense, but there's another `tldr` client.
Namely `ghc-tldr`. It's defined in `gnu/packages/haskell-xyz.scm`.
If it's okay with you, I'll leave `python-tldr` in `gnu/packages/python-xyz.scm`.
>> + (source
>> + (origin
>> + (method url-fetch)
>> + (uri (pypi-uri "tldr" version))
>> + (sha256
>> + (base32
>> + "00h43xjrzrayy1gysvmql5kfabk2d8xraih68d41616brdvb1xvf"))))
>> + (build-system python-build-system)
>> + (native-inputs
>> + `(("python-pytest" ,python-pytest)
>> + ("python-pytest-runner" ,python-pytest-runner)))
>
> The tests for this one are not distributed in the PyPI release. Could
> you source from the homepage instead?
>
> There is one test that tries to open a network connection, it will have
> to be skipped.
Done.
>
>> + (propagated-inputs
>> + `(("python-argcomplete" ,python-argcomplete)
>> + ("python-colorama" ,python-colorama)
>> + ("python-termcolor" ,python-termcolor)))
>
> If it is only a command line tool, inputs should be normal inputs here.
Done.
>> + (description "This package provides the `tldr' command allowing
>> users
>> +to view `tldr' pages from a shell. The `tldr' pages are a community
>> effort
>> +to simplify the man pages with practical examples.")
>
> The linter made this complaint for the description: "use @code or
> similar ornament instead of quotes".
Done.
The new patch is following in another email…
Regards,
--
Tanguy
^ permalink raw reply [flat|nested] 6+ messages in thread
* [bug#46616] [PATCH v2] gnu: Add python-tldr.
2021-02-18 14:06 [bug#46616] [PATCH] gnu: Add python-tldr Tanguy Le Carrour
2021-05-23 21:15 ` Vinicius Monego
@ 2021-06-06 14:16 ` Tanguy Le Carrour
2021-07-20 19:12 ` bug#46616: " Efraim Flashner
1 sibling, 1 reply; 6+ messages in thread
From: Tanguy Le Carrour @ 2021-06-06 14:16 UTC (permalink / raw)
To: 46616; +Cc: monego, Tanguy Le Carrour
* gnu/packages/python-xyz.scm (python-tldr): New variable.
---
gnu/packages/python-xyz.scm | 38 ++++++++++++++++++++++++++++++++++++-
1 file changed, 37 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index a4fe31a01f..bc8c2133f5 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -66,7 +66,7 @@
;;; Copyright © 2019 Jacob MacDonald <jaccarmac@gmail.com>
;;; Copyright © 2019, 2020 Giacomo Leidi <goodoldpaul@autistici.org>
;;; Copyright © 2019 Wiktor Żelazny <wzelazny@vurv.cz>
-;;; Copyright © 2019, 2020 Tanguy Le Carrour <tanguy@bioneland.org>
+;;; Copyright © 2019, 2020, 2021 Tanguy Le Carrour <tanguy@bioneland.org>
;;; Copyright © 2019, 2021 Mădălin Ionel Patrașcu <madalinionel.patrascu@mdc-berlin.de>
;;; Copyright © 2020 Riku Viitanen <riku.viitanen@protonmail.com>
;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
@@ -20825,6 +20825,42 @@ Public Suffix List's private domains as well.")
(define-public python2-tldextract
(package-with-python2 python-tldextract))
+(define-public python-tldr
+ (package
+ (name "python-tldr")
+ (version "1.2.1")
+ (source
+ (origin
+ ;; There's no test in PyPI.
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/tldr-pages/tldr-python-client")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0n9wqvjxspm18vlxf9j9slrcydshk4rkv5nwkrqhfq606n6zvks4"))))
+ (build-system python-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (replace 'check
+ (lambda _
+ ;; This test fails. It tries to open a network socket.
+ (invoke "pytest" "-vv" "-k" "not test_error_message"))))))
+ (native-inputs
+ `(("python-pytest" ,python-pytest)
+ ("python-pytest-runner" ,python-pytest-runner)))
+ (inputs
+ `(("python-argcomplete" ,python-argcomplete)
+ ("python-colorama" ,python-colorama)
+ ("python-termcolor" ,python-termcolor)))
+ (home-page "https://github.com/tldr-pages/tldr-python-client")
+ (synopsis "Python command-line client for tldr pages")
+ (description "This package provides the @code{tldr} command allowing users
+to view @code{tldr} pages from a shell. The `tldr' pages are a community effort
+to simplify the man pages with practical examples.")
+ (license license:expat))) ; MIT license
+
(define-public python-nodeenv
(package
(name "python-nodeenv")
--
2.31.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-07-21 6:11 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-02-18 14:06 [bug#46616] [PATCH] gnu: Add python-tldr Tanguy Le Carrour
2021-05-23 21:15 ` Vinicius Monego
2021-06-06 14:14 ` Tanguy LE CARROUR
2021-06-06 14:16 ` [bug#46616] [PATCH v2] " Tanguy Le Carrour
2021-07-20 19:12 ` bug#46616: " Efraim Flashner
2021-07-21 6:10 ` [bug#46616] " Tanguy LE CARROUR
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).