From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59110) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d8ikc-0001bA-OZ for guix-patches@gnu.org; Thu, 11 May 2017 03:43:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d8ikY-0000Wj-F4 for guix-patches@gnu.org; Thu, 11 May 2017 03:43:06 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:34889) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1d8ikY-0000Wc-Br for guix-patches@gnu.org; Thu, 11 May 2017 03:43:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1d8ikY-000463-65 for guix-patches@gnu.org; Thu, 11 May 2017 03:43:02 -0400 Subject: bug#26876: [Patch]: Add translate-shell Resent-Message-ID: Received: from eggs.gnu.org ([2001:4830:134:3::10]:57697) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d8iip-0000Wv-T3 for guix-patches@gnu.org; Thu, 11 May 2017 03:41:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d8ii2-0007CQ-3p for guix-patches@gnu.org; Thu, 11 May 2017 03:41:15 -0400 Received: from flashner.co.il ([178.62.234.194]:60046) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d8ii1-0007B6-KD for guix-patches@gnu.org; Thu, 11 May 2017 03:40:25 -0400 Received: from localhost (85.64.232.168.dynamic.barak-online.net [85.64.232.168]) by flashner.co.il (Postfix) with ESMTPSA id D80554028A for ; Thu, 11 May 2017 07:40:22 +0000 (UTC) Date: Thu, 11 May 2017 10:40:18 +0300 From: Efraim Flashner Message-ID: <20170511074018.GB27114@macbook42.flashner.co.il> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="W5WqUoFLvi1M7tJE" Content-Disposition: inline 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: 26876@debbugs.gnu.org --W5WqUoFLvi1M7tJE Content-Type: multipart/mixed; boundary="XWOWbaMNXpFDWE00" Content-Disposition: inline --XWOWbaMNXpFDWE00 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I've been using this package for months in my private tree. two things: I don't know if I need to explicitly add curl as an input I don't know if I did the emacs thing correctly; I don't use emacs and I'm not sure how to test it. I tried to do it by copying what some other packages have done. --=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 --XWOWbaMNXpFDWE00 Content-Type: text/plain; charset=utf-8 Content-Disposition: attachment; filename="0001-gnu-Add-translate-shell.patch" Content-Transfer-Encoding: quoted-printable =46rom f0f4b6d10d960b1775a7cf19e94c4fa110475726 Mon Sep 17 00:00:00 2001 =46rom: Efraim Flashner Date: Thu, 11 May 2017 10:36:43 +0300 Subject: [PATCH] gnu: Add translate-shell. * gnu/packages/dictionaries.scm (translate-shell): New variable. --- gnu/packages/dictionaries.scm | 54 +++++++++++++++++++++++++++++++++++++++= +++- 1 file changed, 53 insertions(+), 1 deletion(-) diff --git a/gnu/packages/dictionaries.scm b/gnu/packages/dictionaries.scm index 1e766d73b..df12bf8a3 100644 --- a/gnu/packages/dictionaries.scm +++ b/gnu/packages/dictionaries.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright =C2=A9 2014, 2015, 2016 Ludovic Court=C3=A8s -;;; Copyright =C2=A9 2016 Efraim Flashner +;;; Copyright =C2=A9 2016, 2017 Efraim Flashner ;;; Copyright =C2=A9 2016 Sou Bunnbu ;;; ;;; This file is part of GNU Guix. @@ -25,6 +25,11 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system trivial) #:use-module (gnu packages base) + #:use-module (gnu packages curl) + #:use-module (gnu packages emacs) + #:use-module (gnu packages fribidi) + #:use-module (gnu packages linux) + #:use-module (gnu packages readline) #:use-module (gnu packages texinfo) #:use-module (gnu packages compression) #:use-module (gnu packages tcl)) @@ -200,3 +205,50 @@ work, such as sentence length and other readability me= asures.") It comes with a German-English dictionary with approximately 270,000 entri= es.") (home-page "http://www-user.tu-chemnitz.de/~fri/ding/") (license gpl2+))) + +(define-public translate-shell + (package + (name "translate-shell") + (version "0.9.6.3") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/soimort/" name "/archive/v" + version ".tar.gz")) + (sha256 + (base32 + "13rjq9v3ykk5c0i5daybpnqnyg09cbcgjzykx49h2h5hvspixvi5")) + (file-name (string-append name "-" version ".tar.gz")))) + (build-system gnu-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (delete 'configure) ; no configure phase + (add-after 'install 'emacs-install + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (dest (string-append out "/share/emacs/site-lisp")) + (emacs (string-append (assoc-ref inputs "emacs") "/bin= /emacs"))) + (install-file "google-translate-mode.el" dest) + (emacs-generate-autoloads ,name dest))))) + #:make-flags (list (string-append "PREFIX=3D" %output)) + #:imported-modules (,@%gnu-build-system-modules (guix build emacs-u= tils)) + #:modules ((guix build gnu-build-system) + (guix build emacs-utils) + (guix build utils)) + #:test-target "test")) + (propagated-inputs + `(("curl" ,curl) + ("fribidi" ,fribidi) + ("rlwrap" ,rlwrap))) + (native-inputs + `(("emacs" ,emacs-minimal) + ("util-linux" ,util-linux))) ; hexdump, for the test + (home-page "https://www.soimort.org/translate-shell") + (synopsis "Translations from the command line") + (description + "Translate Shell (formerly Google Translate CLI) is a command-line +translator powered by Google Translate (default), Bing Translator, +Yandex.Translate and Apertium. It gives you easy access to one of these +translation engines from your terminal.") + (license public-domain))) --=20 2.13.0 --XWOWbaMNXpFDWE00-- --W5WqUoFLvi1M7tJE Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEkVdB/rIvpOM7bo+N9MHTkX6s7pMFAlkUFWEACgkQ9MHTkX6s 7pM8hxAApa/2rEl9yKLt+3dNPbACq8Joz3pCZt7mJYkMo8fQjaWDuwmIonf4/ehc AtDx/pAZ4T1m9xS5d/BTR1qlyaw1mVGF75uIirIbe6hfUdIYdLgd35vEbj643fs5 gLNDOlan3vKqNSNdRf1w5JtkCG8QtWec+3NHQYJh5F0i29NUXN6nxs0SnFkr5hmo Oa2rQLmxz5NIbHUDiYbIIVsOu8+4fE+HrHPUMohS3wfSRVAxvKylEm1LKrHM5+f+ /4QQ30KuJtYwyPoWUGxuE+2QYCz5Tuix52zNgi75o28yF7Bbsjjtx24KzW8w7yrW wmtixN5KPdKhlxvyXSITWKw2WBqo80R5G+vVMwpvpyfsjukUkfHBmlEcg5/iwi9V CErQKRrKnMHC4bGGQLhZQ2SSeYM78RmUHRcAiM4rXBUjFyeyQxC/Ku+mpDIdvVwX O5BypQFC0xx+NNc5PYDc8HFDBnK7RgjLiX7r5Z9Tawf097Yvfb8nUQAezoItm4PG RH6926vyd1cRuKnR6wa9fkGvBJPzkOU/uLgNnx51IkUNUaeTbVywecwQDwrRCpDx hCX3iW9PR+5aFwP4bVNc4Qckljd5/g1sEpFa1tht31oeYED4X7EodTwWx3lSUsVX NP3Few5pJ6z0aFVEBKU0lzaYhD20y4+cEkykyi0AH2z29uhLdY4= =+sSi -----END PGP SIGNATURE----- --W5WqUoFLvi1M7tJE--