* [bug#34650] [PATCH 2/7] gnu: Add ruby-tilt.
2019-02-28 17:44 ` [bug#34650] [PATCH 1/7] gnu: ruby-rack-protection: Update to 2.0.5 Pierre Neidhardt
@ 2019-02-28 17:44 ` Pierre Neidhardt
2019-02-28 17:44 ` [bug#34650] [PATCH 3/7] gnu: Add ruby-mustermann Pierre Neidhardt
` (4 subsequent siblings)
5 siblings, 0 replies; 22+ messages in thread
From: Pierre Neidhardt @ 2019-02-28 17:44 UTC (permalink / raw)
To: 34650
* gnu/packages/ruby.scm (ruby-tilt): New variable.
---
gnu/packages/ruby.scm | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 63cfa8cf4..f6b6a19d5 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -7684,3 +7684,27 @@ uniquely identify it.")
serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.")
(home-page "https://github.com/rails/sprockets")
(license license:expat)))
+
+(define-public ruby-tilt
+ (package
+ (name "ruby-tilt")
+ (version "2.0.9")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "tilt" version))
+ (sha256
+ (base32
+ "0ca4k0clwf0rkvy7726x4nxpjxkpv67w043i39saxgldxd97zmwz"))))
+ (build-system ruby-build-system)
+ (arguments
+ ;; TODO: Fix tests.
+ `(#:tests? #f))
+ (synopsis "Generic interface to multiple Ruby template engines")
+ (description "Tilt is a thin interface over a bunch of different Ruby
+template engines in an attempt to make their usage as generic as
+possible. This is useful for web frameworks, static site generators, and other
+systems that support multiple template engines but don't want to code for each
+of them individually.")
+ (home-page "https://github.com/rtomayko/tilt/")
+ (license license:expat)))
--
2.20.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 3/7] gnu: Add ruby-mustermann.
2019-02-28 17:44 ` [bug#34650] [PATCH 1/7] gnu: ruby-rack-protection: Update to 2.0.5 Pierre Neidhardt
2019-02-28 17:44 ` [bug#34650] [PATCH 2/7] gnu: Add ruby-tilt Pierre Neidhardt
@ 2019-02-28 17:44 ` Pierre Neidhardt
2019-03-04 21:20 ` Christopher Baines
2019-02-28 17:44 ` [bug#34650] [PATCH 4/7] gnu: Add ruby-sinatra Pierre Neidhardt
` (3 subsequent siblings)
5 siblings, 1 reply; 22+ messages in thread
From: Pierre Neidhardt @ 2019-02-28 17:44 UTC (permalink / raw)
To: 34650
* gnu/packages/ruby.scm (ruby-mustermann): New variable.
---
gnu/packages/ruby.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index f6b6a19d5..1c10a16c2 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -7708,3 +7708,25 @@ systems that support multiple template engines but don't want to code for each
of them individually.")
(home-page "https://github.com/rtomayko/tilt/")
(license license:expat)))
+
+(define-public ruby-mustermann
+ (package
+ (name "ruby-mustermann")
+ (version "1.0.3")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "mustermann" version))
+ (sha256
+ (base32
+ "0lycgkmnyy0bf29nnd2zql5a6pcf8sp69g9v4xw0gcfcxgpwp7i1"))))
+ (build-system ruby-build-system)
+ (arguments
+ ;; TODO: Fix tests.
+ `(#:tests? #f))
+ (synopsis "Library implementing patterns that behave like regular expressions")
+ (description "Given a string pattern, Mustermann will turn it into an
+object that behaves like a regular expression and has comparable performance
+characteristics.")
+ (home-page "https://github.com/sinatra/mustermann")
+ (license license:expat)))
--
2.20.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 3/7] gnu: Add ruby-mustermann.
2019-02-28 17:44 ` [bug#34650] [PATCH 3/7] gnu: Add ruby-mustermann Pierre Neidhardt
@ 2019-03-04 21:20 ` Christopher Baines
0 siblings, 0 replies; 22+ messages in thread
From: Christopher Baines @ 2019-03-04 21:20 UTC (permalink / raw)
To: Pierre Neidhardt; +Cc: 34650
[-- Attachment #1: Type: text/plain, Size: 1843 bytes --]
Pierre Neidhardt <mail@ambrevar.xyz> writes:
> * gnu/packages/ruby.scm (ruby-mustermann): New variable.
> ---
> gnu/packages/ruby.scm | 22 ++++++++++++++++++++++
> 1 file changed, 22 insertions(+)
>
> diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
> index f6b6a19d5..1c10a16c2 100644
> --- a/gnu/packages/ruby.scm
> +++ b/gnu/packages/ruby.scm
> @@ -7708,3 +7708,25 @@ systems that support multiple template engines but don't want to code for each
> of them individually.")
> (home-page "https://github.com/rtomayko/tilt/")
> (license license:expat)))
> +
> +(define-public ruby-mustermann
> + (package
> + (name "ruby-mustermann")
> + (version "1.0.3")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (rubygems-uri "mustermann" version))
> + (sha256
> + (base32
> + "0lycgkmnyy0bf29nnd2zql5a6pcf8sp69g9v4xw0gcfcxgpwp7i1"))))
> + (build-system ruby-build-system)
> + (arguments
> + ;; TODO: Fix tests.
> + `(#:tests? #f))
Could you include some details of what is broken about the tests? Even
just a bit of the error message if there is one.
Also, I'd usually use a single quote unless a backtick is necessary.
> + (synopsis "Library implementing patterns that behave like regular expressions")
> + (description "Given a string pattern, Mustermann will turn it into an
> +object that behaves like a regular expression and has comparable performance
> +characteristics.")
> + (home-page "https://github.com/sinatra/mustermann")
> + (license license:expat)))
I'd recommend trying to avoid inserting packages at the end of modules,
or generally in the same place. This can make rebases difficult, and
increase the chances of conflicts when going to apply patches. I
generally try to fit patches in to modules somewhat alphabetically.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]
^ permalink raw reply [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 4/7] gnu: Add ruby-sinatra.
2019-02-28 17:44 ` [bug#34650] [PATCH 1/7] gnu: ruby-rack-protection: Update to 2.0.5 Pierre Neidhardt
2019-02-28 17:44 ` [bug#34650] [PATCH 2/7] gnu: Add ruby-tilt Pierre Neidhardt
2019-02-28 17:44 ` [bug#34650] [PATCH 3/7] gnu: Add ruby-mustermann Pierre Neidhardt
@ 2019-02-28 17:44 ` Pierre Neidhardt
2019-02-28 17:44 ` [bug#34650] [PATCH 5/7] gnu: Add ruby-thin Pierre Neidhardt
` (2 subsequent siblings)
5 siblings, 0 replies; 22+ messages in thread
From: Pierre Neidhardt @ 2019-02-28 17:44 UTC (permalink / raw)
To: 34650
* gnu/packages/ruby.scm (ruby-sinatra): New variable.
---
gnu/packages/ruby.scm | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 1c10a16c2..78d113af7 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -7730,3 +7730,27 @@ object that behaves like a regular expression and has comparable performance
characteristics.")
(home-page "https://github.com/sinatra/mustermann")
(license license:expat)))
+
+(define-public ruby-sinatra
+ (package
+ (name "ruby-sinatra")
+ (version "2.0.5")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "sinatra" version))
+ (sha256
+ (base32
+ "1gasgn5f15myv08k10i16p326pchxjsy37pgqfw0xm66kcc5d7ry"))))
+ (build-system ruby-build-system)
+ (propagated-inputs
+ `(("ruby-mustermann" ,ruby-mustermann)
+ ("ruby-rack" ,ruby-rack)
+ ("ruby-rack-protection" ,ruby-rack-protection)
+ ("ruby-tilt" ,ruby-tilt)))
+ (synopsis "DSL for quick web applications creation in Ruby")
+ (description
+ "Sinatra is a DSL for quickly creating web applications in Ruby with
+minimal effort.")
+ (home-page "http://sinatrarb.com/")
+ (license license:expat)))
--
2.20.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 5/7] gnu: Add ruby-thin.
2019-02-28 17:44 ` [bug#34650] [PATCH 1/7] gnu: ruby-rack-protection: Update to 2.0.5 Pierre Neidhardt
` (2 preceding siblings ...)
2019-02-28 17:44 ` [bug#34650] [PATCH 4/7] gnu: Add ruby-sinatra Pierre Neidhardt
@ 2019-02-28 17:44 ` Pierre Neidhardt
2019-03-04 21:33 ` Christopher Baines
2019-02-28 17:44 ` [bug#34650] [PATCH 6/7] gnu: Add ruby-skinny Pierre Neidhardt
2019-02-28 17:44 ` [bug#34650] [PATCH 7/7] gnu: Add mailcatcher Pierre Neidhardt
5 siblings, 1 reply; 22+ messages in thread
From: Pierre Neidhardt @ 2019-02-28 17:44 UTC (permalink / raw)
To: 34650
* gnu/packages/ruby.scm (ruby-thin): New variable.
---
gnu/packages/ruby.scm | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 78d113af7..9d3c4b246 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -7754,3 +7754,32 @@ characteristics.")
minimal effort.")
(home-page "http://sinatrarb.com/")
(license license:expat)))
+
+(define-public ruby-thin
+ (package
+ (name "ruby-thin")
+ (version "1.7.2")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "thin" version))
+ (sha256
+ (base32
+ "0nagbf9pwy1vg09k6j4xqhbjjzrg5dwzvkn4ffvlj76fsn6vv61f"))))
+ (build-system ruby-build-system)
+ (arguments
+ ;; TODO: Fix tests.
+ `(#:tests? #f))
+ (propagated-inputs
+ `(("ruby-daemons" ,ruby-daemons)
+ ("ruby-eventmachine" ,ruby-eventmachine)
+ ("ruby-rack" ,ruby-rack)))
+ (synopsis "Thin and fast web server for Ruby")
+ (description "Thin is a Ruby web server that glues together 3 Ruby libraries:
+@itemize
+@item the Mongrel parser,
+@item Event Machine, a network I/O library with high scalability, performance and stability
+@item Rack, a minimal interface between webservers and Ruby frameworks
+@end itemize\n")
+ (home-page "http://code.macournoyer.com/thin/")
+ (license license:ruby)))
--
2.20.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 5/7] gnu: Add ruby-thin.
2019-02-28 17:44 ` [bug#34650] [PATCH 5/7] gnu: Add ruby-thin Pierre Neidhardt
@ 2019-03-04 21:33 ` Christopher Baines
0 siblings, 0 replies; 22+ messages in thread
From: Christopher Baines @ 2019-03-04 21:33 UTC (permalink / raw)
To: Pierre Neidhardt; +Cc: 34650
[-- Attachment #1: Type: text/plain, Size: 1645 bytes --]
Pierre Neidhardt <mail@ambrevar.xyz> writes:
> * gnu/packages/ruby.scm (ruby-thin): New variable.
> ---
> gnu/packages/ruby.scm | 29 +++++++++++++++++++++++++++++
> 1 file changed, 29 insertions(+)
>
> diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
> index 78d113af7..9d3c4b246 100644
> --- a/gnu/packages/ruby.scm
> +++ b/gnu/packages/ruby.scm
> @@ -7754,3 +7754,32 @@ characteristics.")
> minimal effort.")
> (home-page "http://sinatrarb.com/")
> (license license:expat)))
> +
> +(define-public ruby-thin
> + (package
> + (name "ruby-thin")
> + (version "1.7.2")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (rubygems-uri "thin" version))
> + (sha256
> + (base32
> + "0nagbf9pwy1vg09k6j4xqhbjjzrg5dwzvkn4ffvlj76fsn6vv61f"))))
> + (build-system ruby-build-system)
> + (arguments
> + ;; TODO: Fix tests.
> + `(#:tests? #f))
As with the other package, it would be good to put at least some
information here about what the problem is.
> + (propagated-inputs
> + `(("ruby-daemons" ,ruby-daemons)
> + ("ruby-eventmachine" ,ruby-eventmachine)
> + ("ruby-rack" ,ruby-rack)))
> + (synopsis "Thin and fast web server for Ruby")
> + (description "Thin is a Ruby web server that glues together 3 Ruby libraries:
> +@itemize
> +@item the Mongrel parser,
> +@item Event Machine, a network I/O library with high scalability, performance and stability
> +@item Rack, a minimal interface between webservers and Ruby frameworks
> +@end itemize\n")
> + (home-page "http://code.macournoyer.com/thin/")
> + (license license:ruby)))
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]
^ permalink raw reply [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 6/7] gnu: Add ruby-skinny.
2019-02-28 17:44 ` [bug#34650] [PATCH 1/7] gnu: ruby-rack-protection: Update to 2.0.5 Pierre Neidhardt
` (3 preceding siblings ...)
2019-02-28 17:44 ` [bug#34650] [PATCH 5/7] gnu: Add ruby-thin Pierre Neidhardt
@ 2019-02-28 17:44 ` Pierre Neidhardt
2019-03-04 21:43 ` Christopher Baines
2019-02-28 17:44 ` [bug#34650] [PATCH 7/7] gnu: Add mailcatcher Pierre Neidhardt
5 siblings, 1 reply; 22+ messages in thread
From: Pierre Neidhardt @ 2019-02-28 17:44 UTC (permalink / raw)
To: 34650
* gnu/packages/ruby.scm (ruby-skinny): New variable.
---
gnu/packages/ruby.scm | 31 +++++++++++++++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 9d3c4b246..8cb170e17 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -7783,3 +7783,34 @@ minimal effort.")
@end itemize\n")
(home-page "http://code.macournoyer.com/thin/")
(license license:ruby)))
+
+(define-public ruby-skinny
+ (package
+ (name "ruby-skinny")
+ (version "0.2.4")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "skinny" version))
+ (sha256
+ (base32
+ "1y3yvx88ylgz4d2s1wskjk5rkmrcr15q3ibzp1q88qwzr5y493a9"))))
+ (build-system ruby-build-system)
+ (arguments
+ ;; TODO: Grab from GitHub to get tests?
+ `(#:tests? #f
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'patch-gemspec
+ (lambda _
+ (substitute* ".gemspec"
+ (("<eventmachine>.freeze, \\[\\\"~> 1.0.0\"")
+ "<eventmachine>, [\">= 1.0.0\"")
+ (("<thin>.freeze, \\[\\\"< 1.7\", ") "<thin>, [")))))))
+ (propagated-inputs
+ `(("ruby-eventmachine" ,ruby-eventmachine)
+ ("ruby-thin" ,ruby-thin)))
+ (synopsis "Simple, upgradable WebSockets for Ruby Thin")
+ (description "Simple, upgradable WebSockets for Ruby Thin.")
+ (home-page "https://github.com/sj26/skinny")
+ (license license:expat)))
--
2.20.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 6/7] gnu: Add ruby-skinny.
2019-02-28 17:44 ` [bug#34650] [PATCH 6/7] gnu: Add ruby-skinny Pierre Neidhardt
@ 2019-03-04 21:43 ` Christopher Baines
0 siblings, 0 replies; 22+ messages in thread
From: Christopher Baines @ 2019-03-04 21:43 UTC (permalink / raw)
To: Pierre Neidhardt; +Cc: 34650
[-- Attachment #1: Type: text/plain, Size: 1938 bytes --]
Pierre Neidhardt <mail@ambrevar.xyz> writes:
> * gnu/packages/ruby.scm (ruby-skinny): New variable.
> ---
> gnu/packages/ruby.scm | 31 +++++++++++++++++++++++++++++++
> 1 file changed, 31 insertions(+)
>
> diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
> index 9d3c4b246..8cb170e17 100644
> --- a/gnu/packages/ruby.scm
> +++ b/gnu/packages/ruby.scm
> @@ -7783,3 +7783,34 @@ minimal effort.")
> @end itemize\n")
> (home-page "http://code.macournoyer.com/thin/")
> (license license:ruby)))
> +
> +(define-public ruby-skinny
> + (package
> + (name "ruby-skinny")
> + (version "0.2.4")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (rubygems-uri "skinny" version))
> + (sha256
> + (base32
> + "1y3yvx88ylgz4d2s1wskjk5rkmrcr15q3ibzp1q88qwzr5y493a9"))))
> + (build-system ruby-build-system)
> + (arguments
> + ;; TODO: Grab from GitHub to get tests?
> + `(#:tests? #f
If there are no tests, I'd just put:
'(#:tests? #f ; No included tests
> + #:phases
> + (modify-phases %standard-phases
> + (add-before 'build 'patch-gemspec
> + (lambda _
> + (substitute* ".gemspec"
> + (("<eventmachine>.freeze, \\[\\\"~> 1.0.0\"")
> + "<eventmachine>, [\">= 1.0.0\"")
> + (("<thin>.freeze, \\[\\\"< 1.7\", ") "<thin>, [")))))))
Adding a explicit #t at the end of this phase.
> + (propagated-inputs
> + `(("ruby-eventmachine" ,ruby-eventmachine)
> + ("ruby-thin" ,ruby-thin)))
> + (synopsis "Simple, upgradable WebSockets for Ruby Thin")
> + (description "Simple, upgradable WebSockets for Ruby Thin.")
The synopsis and description are the same. Even if there is no more
information to add, it would be good to at least provide a slightly
different description.
> + (home-page "https://github.com/sj26/skinny")
> + (license license:expat)))
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]
^ permalink raw reply [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 7/7] gnu: Add mailcatcher.
2019-02-28 17:44 ` [bug#34650] [PATCH 1/7] gnu: ruby-rack-protection: Update to 2.0.5 Pierre Neidhardt
` (4 preceding siblings ...)
2019-02-28 17:44 ` [bug#34650] [PATCH 6/7] gnu: Add ruby-skinny Pierre Neidhardt
@ 2019-02-28 17:44 ` Pierre Neidhardt
2019-03-04 21:50 ` Christopher Baines
5 siblings, 1 reply; 22+ messages in thread
From: Pierre Neidhardt @ 2019-02-28 17:44 UTC (permalink / raw)
To: 34650
* 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
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'patch-gemspec
+ (lambda _
+ (substitute* ".gemspec"
+ (("<eventmachine>.freeze, \\[\\\"= 1.0.9.1") "<eventmachine>, [\">= 1.0.9.1")
+ (("<rack>.freeze, \\[\\\"~> 1.5") "<rack>, [\">= 1.5")
+ (("<thin>.freeze, \\[\\\"~> 1.5.0") "<thin>, [\">= 1.5.0")
+ (("<sinatra>.freeze, \\[\\\"~> 1.2") "<sinatra>, [\">= 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\"")))))))
+ (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)))
--
2.20.1
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 7/7] gnu: Add mailcatcher.
2019-02-28 17:44 ` [bug#34650] [PATCH 7/7] gnu: Add mailcatcher Pierre Neidhardt
@ 2019-03-04 21:50 ` Christopher Baines
2019-03-05 9:09 ` Pierre Neidhardt
0 siblings, 1 reply; 22+ messages in thread
From: Christopher Baines @ 2019-03-04 21:50 UTC (permalink / raw)
To: Pierre Neidhardt; +Cc: 34650
[-- Attachment #1: Type: text/plain, Size: 3087 bytes --]
Pierre Neidhardt <mail@ambrevar.xyz> 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"
> + (("<eventmachine>.freeze, \\[\\\"= 1.0.9.1") "<eventmachine>, [\">= 1.0.9.1")
> + (("<rack>.freeze, \\[\\\"~> 1.5") "<rack>, [\">= 1.5")
> + (("<thin>.freeze, \\[\\\"~> 1.5.0") "<thin>, [\">= 1.5.0")
> + (("<sinatra>.freeze, \\[\\\"~> 1.2") "<sinatra>, [\">= 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)))
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]
^ permalink raw reply [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 7/7] gnu: Add mailcatcher.
2019-03-04 21:50 ` Christopher Baines
@ 2019-03-05 9:09 ` Pierre Neidhardt
2019-03-05 10:27 ` Pierre Neidhardt
2019-03-05 18:51 ` Christopher Baines
0 siblings, 2 replies; 22+ messages in thread
From: Pierre Neidhardt @ 2019-03-05 9:09 UTC (permalink / raw)
To: Christopher Baines; +Cc: 34650
Thanks for the review!
> I'd recommend trying to avoid inserting packages at the end of modules,
> or generally in the same place. This can make rebases difficult, and
> increase the chances of conflicts when going to apply patches. I
> generally try to fit patches in to modules somewhat alphabetically.
You are very true here, but currently ruby.scm seems to follow no order
whatsoever. Not sure where to insert the new packages then.
--
Pierre Neidhardt
https://ambrevar.xyz/
^ permalink raw reply [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 7/7] gnu: Add mailcatcher.
2019-03-05 9:09 ` Pierre Neidhardt
@ 2019-03-05 10:27 ` Pierre Neidhardt
2019-03-05 18:51 ` Christopher Baines
1 sibling, 0 replies; 22+ messages in thread
From: Pierre Neidhardt @ 2019-03-05 10:27 UTC (permalink / raw)
To: Christopher Baines; +Cc: 34650
I've taken all your comments into accounts (hopefully).
I did not manage to run the test suite for mailcatcher. I've added a
comment explaining what's going on, but I don't know enough Ruby to fix
it properly.
I've pushed to master.
Thanks again for your review!
--
Pierre Neidhardt
https://ambrevar.xyz/
^ permalink raw reply [flat|nested] 22+ messages in thread
* [bug#34650] [PATCH 7/7] gnu: Add mailcatcher.
2019-03-05 9:09 ` Pierre Neidhardt
2019-03-05 10:27 ` Pierre Neidhardt
@ 2019-03-05 18:51 ` Christopher Baines
1 sibling, 0 replies; 22+ messages in thread
From: Christopher Baines @ 2019-03-05 18:51 UTC (permalink / raw)
To: Pierre Neidhardt; +Cc: 34650
[-- Attachment #1: Type: text/plain, Size: 691 bytes --]
Pierre Neidhardt <pierre@atlas.engineer> writes:
> Thanks for the review!
>
>> I'd recommend trying to avoid inserting packages at the end of modules,
>> or generally in the same place. This can make rebases difficult, and
>> increase the chances of conflicts when going to apply patches. I
>> generally try to fit patches in to modules somewhat alphabetically.
>
> You are very true here, but currently ruby.scm seems to follow no order
> whatsoever. Not sure where to insert the new packages then.
Well, it's in no strict order. One approach I normally use is to start
at the top and work my way down, and fit packages in just below the
first thing that's before them in the alphabet.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 962 bytes --]
^ permalink raw reply [flat|nested] 22+ messages in thread