From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:37595) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iyLNb-0000va-BO for guix-patches@gnu.org; Sun, 02 Feb 2020 14:58:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iyLNZ-0007jJ-Re for guix-patches@gnu.org; Sun, 02 Feb 2020 14:58:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:34606) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iyLNZ-0007jE-O6 for guix-patches@gnu.org; Sun, 02 Feb 2020 14:58:01 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iyLNZ-0007Nm-NA for guix-patches@gnu.org; Sun, 02 Feb 2020 14:58:01 -0500 Subject: [bug#39396] [PATCH] gnu: Add grip. Resent-Message-ID: Date: Sun, 2 Feb 2020 21:56:25 +0200 From: Efraim Flashner Message-ID: <20200202195625.GJ9517@E5400> References: <20200202193545.17621-1-kuba@kadziolka.net> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="AYsPlKobQGgtCvjI" Content-Disposition: inline In-Reply-To: <20200202193545.17621-1-kuba@kadziolka.net> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Jakub =?UTF-8?Q?K=C4=85dzio=C5=82ka?= Cc: 39396@debbugs.gnu.org --AYsPlKobQGgtCvjI Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Feb 02, 2020 at 08:35:45PM +0100, Jakub K=C4=85dzio=C5=82ka wrote: > * gnu/packages/python-web.scm (grip, python-path-and-address): New > variables. Please split this into two patches. > --- > gnu/packages/python-web.scm | 59 +++++++++++++++++++++++++++++++++++++ > 1 file changed, 59 insertions(+) >=20 > diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm > index 9464021d82..a6b1e97ba1 100644 > --- a/gnu/packages/python-web.scm > +++ b/gnu/packages/python-web.scm > @@ -31,6 +31,7 @@ > ;;; Copyright =C2=A9 2019 Brendan Tildesley > ;;; Copyright =C2=A9 2019 Pierre Langlois > ;;; Copyright =C2=A9 2019 Tanguy Le Carrour > +;;; Copyright =C2=A9 2020 Jakub K=C4=85dzio=C5=82ka > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -3494,3 +3495,61 @@ is part of the Weblate translation platform.") > (description "This package provides an extended library for interact= ing > with GitLab instances through their API.") > (license license:lgpl3+))) > + > +(define-public python-path-and-address > + (package > + (name "python-path-and-address") > + (version "2.0.1") > + (source > + (origin > + ;; Use git-fetch because pypi-url fails. I managed to get the pypi importer to work: guix environment --ad-hoc unzip -- guix import pypi path-and-address just make sure to add the ".zip" at the end of the uri of the generated package. > + (method git-fetch) > + (uri (git-reference > + (url "https://github.com/joeyespo/path-and-address") > + (commit (string-append "v" version)))) > + (file-name (git-file-name name version)) > + (sha256 > + (base32 > + "0b0afpsaim06mv3lhbpm8fmawcraggc11jhzr6h72kdj1cqjk5h6")))) > + (build-system python-build-system) This package didn't show any tests run, so after some experimentation I ended up with the following addition: (arguments `(#:phases (modify-phases %standard-phases (replace 'check (lambda* (#:key inputs outputs #:allow-other-keys) (add-installed-pythonpath inputs outputs) (invoke "py.test")))))) (native-inputs `(("python-pytest" ,python-pytest))) > + (home-page "https://github.com/joeyespo/path-and-address") > + (synopsis "Functions for command-line server tools used by humans") > + (description "Path-and-address resolves ambiguities of command-line > +interfaces, inferring which argument is the path, and which is the addre= ss.") > + (license license:expat))) > + This package I also didn't see run any tests. I'd suggest checking out the .travis.yml file to see what they do for the tests. > +(define-public grip > + ;; No release by upstream for quite some time, some bugs fixed since. = See: > + ;; https://github.com/joeyespo/grip/issues/304 > + (let ((commit "27a4d6d87ea1d0ea7f7f120de55baabee3de73e3")) > + (package > + (name "grip") > + (version (git-version "4.5.2" "1" commit)) > + (source > + (origin > + (method git-fetch) > + (uri (git-reference > + (url "https://github.com/joeyespo/grip") > + (commit commit))) > + (file-name (git-file-name name version)) > + (sha256 > + (base32 > + "0kx5hgb3q19i4l18a4vqdq9af390xgpk88lp2ay75qi96k0dc68w")))) > + (build-system python-build-system) > + (propagated-inputs > + `(("python-docopt" ,python-docopt) > + ("python-flask" ,python-flask) > + ("python-markdown" ,python-markdown) > + ("python-path-and-address" ,python-path-and-address) > + ("python-pygments" ,python-pygments) > + ("python-requests" ,python-requests))) > + (native-inputs > + `(("python-responses" ,python-responses))) > + (home-page "https://github.com/joeyespo/grip") > + (synopsis "Preview Markdown files using the GitHub API") > + (description "Grip is a command-line server application written in= Python > +that uses the GitHub Markdown API to render a local Markdown file. The = styles > +and rendering come directly from GitHub, so you'll know exactly how it w= ill > +appear. Changes you make to the file will be instantly reflected in the= browser > +without requiring a page refresh.") > + (license license:expat)))) > --=20 > 2.25.0 >=20 >=20 >=20 >=20 --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --AYsPlKobQGgtCvjI Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAl43KWUACgkQQarn3Mo9 g1GlCQ/9Hho8IqnBsQx2EEKyYSq6IIruydZT2w18x4mDpaeCfd/Y2CXPwsbvZIey b510cdHAIYoJoHqAwpO3lemGb0tWIN/Lbjjq5Sqy76sFDDsbz/WUjVXfSDCvrtCx 76WdubrlEhrugJL0mbs/rZjQlibnPmnJDDK7PBIKhHRfntUEMnvqCRN4tNWIQzw6 se5eCcSxp+ZHnoLePcqNws8EQhGbeE6QhMWW2uwiO2BSR/szearkBBytXkZO7aO5 w8HK/kE4GMM2XKz9KyfZZLv4OILB63ajRkuVTW5xgQxC088Kzyriinzra6PFtoae nEbqMnb2/acVCmM/GKPwu15xHAymPHD5XBREYKt1rrh0dXWArlbjyNtVJLGkrLw0 B+9GiVjianwlf+fWMdbHLVJsw7CJmWn+TyIs1Mk0841GIqIYXZVnzbUy4sZCZV8N fmvadInVRJV4P8bGuw6okQtBAtH/ARaJdSH9eRfBGx78cKdauM1cx4c8XqfYiPnU Rp2Yik3PrOioPb2sYyQiyYPBl2a6gJY7rwVYtou0Co31XdXAYMdlBHFBMZbGsDzR MIToVuYSPmxts2G3U0P+F9lRJEEtg+lHF7ZkIQLZ1Ct7Tca3vhcwidxgQDQCh4ic uyzj2i0U7d9xC3rVoSTFQYE82T3ywmvEgkRwwQDa8JC2llYXNpk= =vkUJ -----END PGP SIGNATURE----- --AYsPlKobQGgtCvjI--