From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([209.51.188.92]:43663) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1h0vUJ-0007nL-VV for guix-patches@gnu.org; Mon, 04 Mar 2019 16:51:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1h0vUI-0002Qp-V6 for guix-patches@gnu.org; Mon, 04 Mar 2019 16:51:07 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:46784) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1h0vUE-0002NO-Lg for guix-patches@gnu.org; Mon, 04 Mar 2019 16:51:05 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1h0vUE-0001Fo-Fg for guix-patches@gnu.org; Mon, 04 Mar 2019 16:51:02 -0500 Subject: [bug#34650] [PATCH 7/7] gnu: Add mailcatcher. Resent-Message-ID: References: <87ftsa24ts.fsf@ambrevar.xyz> <20190228174435.14499-1-mail@ambrevar.xyz> <20190228174435.14499-7-mail@ambrevar.xyz> From: Christopher Baines In-reply-to: <20190228174435.14499-7-mail@ambrevar.xyz> Date: Mon, 04 Mar 2019 21:50:05 +0000 Message-ID: <87fts2fgxe.fsf@cbaines.net> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" 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: Pierre Neidhardt Cc: 34650@debbugs.gnu.org --=-=-= Content-Type: text/plain Pierre Neidhardt writes: > * gnu/packages/ruby.scm (mailcatcher): New variable. > --- > gnu/packages/ruby.scm | 49 +++++++++++++++++++++++++++++++++++++++++++ > 1 file changed, 49 insertions(+) > > diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm > index 8cb170e17..854b4669b 100644 > --- a/gnu/packages/ruby.scm > +++ b/gnu/packages/ruby.scm > @@ -7814,3 +7814,52 @@ minimal effort.") > (description "Simple, upgradable WebSockets for Ruby Thin.") > (home-page "https://github.com/sj26/skinny") > (license license:expat))) > + > +(define-public mailcatcher > + (package > + (name "mailcatcher") > + (version "0.6.5") > + (source > + (origin > + (method url-fetch) > + (uri (rubygems-uri "mailcatcher" version)) > + (sha256 > + (base32 > + "0h6gk8n18i5f651f244al1hscjzl27fpma4vqw0qhszqqpd5p3bx")))) > + (build-system ruby-build-system) > + (arguments > + ;; TODO: Grab from GitHub to get tests? > + `(#:tests? #f As with ruby-skinny, if there are no tests, I'd put: '(#:tests? #f ; No included tests > + #:phases > + (modify-phases %standard-phases > + (add-before 'build 'patch-gemspec > + (lambda _ > + (substitute* ".gemspec" > + ((".freeze, \\[\\\"= 1.0.9.1") ", [\">= 1.0.9.1") > + ((".freeze, \\[\\\"~> 1.5") ", [\">= 1.5") > + ((".freeze, \\[\\\"~> 1.5.0") ", [\">= 1.5.0") > + ((".freeze, \\[\\\"~> 1.2") ", [\">= 1.2") > + ))) > + (add-before 'build 'loosen-dependency-contraint > + (lambda _ > + (substitute* "lib/mail_catcher.rb" > + (("\"eventmachine\", \"1.0.9.1\"") "\"eventmachine\", \">= 1.0.9.1\"") > + (("\"rack\", \"~> 1.5\"") "\"rack\", \">= 1.5\"") > + (("\"thin\", \"~> 1.5.0\"") "\"thin\", \">= 1.5.0\"") > + (("\"sinatra\", \"~> 1.2\"") "\"sinatra\", \">= 1.2\""))))))) I'd add an explicit #t at the end of these phases. Also, using wildcards in place of the versions in the mailcatcher gem would probably make it easier to update this package if new versions are released. > + (inputs > + `(("ruby-eventmachine" ,ruby-eventmachine) > + ("ruby-mail" ,ruby-mail) > + ("ruby-rack" ,ruby-rack) > + ("ruby-sinatra" ,ruby-sinatra) > + ("ruby-skinny" ,ruby-skinny) > + ("ruby-sqlite3" ,ruby-sqlite3) > + ("ruby-thin" ,ruby-thin))) > + (synopsis "Run an SMTP server which catches any message sent to it to display in a browser") > + (description > + "MailCatcher runs a super simple SMTP server which catches any message > +sent to it to display in a web interface. Run mailcatcher, set your favourite > +app to deliver to smtp://127.0.0.1:1025 instead of your default SMTP server, > +then check out http://127.0.0.1:1080 to see the mail.") > + (home-page "https://mailcatcher.me") > + (license license:expat))) --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAlx9nY1fFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9XflGg/9GNkAxpkzHsD9MJiwkhH0Ue22vPVUiepjvDGCVCyWVJkr45/d6lUYQkqF oPlr6n/kKkN5UYwoNc8gE+9FySRaRPmT53iBx1cRWFmXzxw7GH6LQThO8POf5ori GOqqH89zE4PhjPgNQh5V68sCfPOf4QHlyt9W504ez6+FkNZ9IWaeFzxbyKS0eIDN QzRyIC2MFdLb0gqn48mtWNx5nYMOIsXKIDPuKMKzzPJNDh+m+dtic0bqsTmAli1b yniKb1IVIT4pE0gpDWkVXk60vsRGVOpUk6Ih1PPNXpIxv3u4gxkZbyadlLBBx5st yl77MkA615TYtcvJQbS9Z0aNGg6Q8fv02y3PsIx+2K8KqukIFHOpqqLYO9qGXeo9 9tSaa/jQuih56A/2/2IxkKoiZEBi50s3jwiSG1k/NOQeFar9ZmwpLFsvl+tn3Clj USynvHH+89ZJvoFdChLRpeycnGFhrKELgSPyZVgVAdS4P0Ml+MF5AuJDGwtP63tG 0aXiWtireWzera5TgPUm3ZQIYmoiyindEQ3ztcMSwnbQzGWijsMcSVmT+YQrC8tR Av2SNsKTBiYj0T77daD/IOe/Q99xm1Xw44Q5PacZt9X/jcAk4T0AMtia1G7cy/DP SAQkB9BsQBQVNcUd0rFyD8X7B8yB7bZlfDowYkNL1p4OyYm66BY= =T9vC -----END PGP SIGNATURE----- --=-=-=--