From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55179) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dwAXe-0007py-99 for guix-patches@gnu.org; Sun, 24 Sep 2017 13:18:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dwAXd-00089I-0T for guix-patches@gnu.org; Sun, 24 Sep 2017 13:18:06 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:47687) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dwAXc-00089E-Sf for guix-patches@gnu.org; Sun, 24 Sep 2017 13:18:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dwAXc-0006kH-Mi for guix-patches@gnu.org; Sun, 24 Sep 2017 13:18:04 -0400 Subject: [bug#28583] [PATCH 1/7] gnu: Add ruby-httpclient. References: <20170924181052.0219647c@cbaines.net> In-Reply-To: <20170924181052.0219647c@cbaines.net> Resent-Message-ID: From: Christopher Baines Date: Sun, 24 Sep 2017 18:17:11 +0100 Message-Id: <20170924171717.3855-1-mail@cbaines.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: 28583@debbugs.gnu.org * gnu/packages/ruby.scm (ruby-httpclient): New variable. --- gnu/packages/ruby.scm | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index 80d3bffd8..ff6be875f 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -3579,6 +3579,57 @@ It has built-in support for the legacy @code{cookies.txt} and (home-page "https://github.com/sparklemotion/http-cookie") (license license:expat))) +(define-public ruby-httpclient + (package + (name "ruby-httpclient") + (version "2.8.3") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "httpclient" version)) + (sha256 + (base32 + "19mxmvghp7ki3klsxwrlwr431li7hm1lczhhj8z4qihl2acy8l99")))) + (build-system ruby-build-system) + (arguments + '(;; TODO: Some tests currently fail + ;; ------ + ;; 211 tests, 729 assertions, 13 failures, 4 errors, 0 pendings, + ;; 2 omissions, 0 notifications + ;; 91.866% passed + ;; ------ + ;; 6.49 tests/s, 22.41 assertions/s + #:tests? #f + #:phases + (modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (if tests? + (zero? + (system* "ruby" + "-Ilib" + "test/runner.rb")) + #t))) + (add-after 'install 'wrap-bin-httpclient + (lambda* (#:key outputs #:allow-other-keys) + (wrap-program (string-append (assoc-ref outputs "out") + "/bin/httpclient") + `("GEM_HOME" ":" prefix (,(getenv "GEM_HOME")))) + #t))))) + (native-inputs + `(("ruby-rack" ,ruby-rack))) + (synopsis + "Make HTTP requests with support for HTTPS, Cookies, authentication and more") + (description + "The @code{httpclient} ruby library provides functionality related to +HTTP. Compared to the @code{net/http} library, @{httpclient} also provides +Cookie, multithreading and authentication (digest, NTLM) support. + +Also provided is a @command{httpclient} command, which can perform HTTP +requests either using arguments or with an interactive prompt.") + (home-page "https://github.com/nahi/httpclient") + (license license:ruby))) + (define-public ruby-ansi (package (name "ruby-ansi") -- 2.14.1