summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans de Graaff <graaff@gentoo.org>2024-11-16 09:10:39 +0100
committerHans de Graaff <graaff@gentoo.org>2024-11-16 09:12:11 +0100
commitb8f2dca98463b9ca6db552fc9633a38a64e1fa26 (patch)
treecf336e965a2ab7f7253de40e5c20de56f33a6292 /dev-ruby
parentdev-ruby/faraday-net_http_persistent: add 2.3.0 (diff)
downloadgentoo-b8f2dca98463b9ca6db552fc9633a38a64e1fa26.tar.gz
gentoo-b8f2dca98463b9ca6db552fc9633a38a64e1fa26.tar.bz2
gentoo-b8f2dca98463b9ca6db552fc9633a38a64e1fa26.zip
dev-ruby/faraday_middleware: add 1.2.1
Signed-off-by: Hans de Graaff <graaff@gentoo.org>
Diffstat (limited to 'dev-ruby')
-rw-r--r--dev-ruby/faraday_middleware/Manifest1
-rw-r--r--dev-ruby/faraday_middleware/faraday_middleware-1.2.1.ebuild69
2 files changed, 70 insertions, 0 deletions
diff --git a/dev-ruby/faraday_middleware/Manifest b/dev-ruby/faraday_middleware/Manifest
index ac88971867e8..0c783fa430c7 100644
--- a/dev-ruby/faraday_middleware/Manifest
+++ b/dev-ruby/faraday_middleware/Manifest
@@ -1 +1,2 @@
DIST faraday_middleware-1.2.0.tar.gz 28332 BLAKE2B 09aefce13f0145e4098d68d2b8887fff5b535b3eda520335fdcaeea05256d1a256501fe9fee4273636fb0bb9d806d38ff7588a489840d2e425ce6666c496a4d1 SHA512 abfc6faf725c4646d0c1c59d2bde23db13dd78f81e74d313368bd0ec4945c33f24c8e8f3f252c6fa499fa845bdda19544876ea93bb9118b3fa4d3c7615366283
+DIST faraday_middleware-1.2.1.tar.gz 28765 BLAKE2B aa5b59301b5a51fa4bc424644096b7a26617ad5d8e93bce592807a3a4a3cb405f52398fb90b95089a7095489d2543c6b033ec709dd640ac6d73a0173312bff94 SHA512 23e03c011657c1fdefd47764944d4699cd6b3f96c0e7dd01c129381a5237239aeaefa193da558d70f0c43e093627fc0a5f8d08b820b178525f38033ab85d5798
diff --git a/dev-ruby/faraday_middleware/faraday_middleware-1.2.1.ebuild b/dev-ruby/faraday_middleware/faraday_middleware-1.2.1.ebuild
new file mode 100644
index 000000000000..66aaee773021
--- /dev/null
+++ b/dev-ruby/faraday_middleware/faraday_middleware-1.2.1.ebuild
@@ -0,0 +1,69 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+USE_RUBY="ruby31 ruby32"
+
+RUBY_FAKEGEM_RECIPE_TEST="rspec3"
+
+RUBY_FAKEGEM_EXTRADOC="README.md"
+
+RUBY_FAKEGEM_GEMSPEC="${PN}.gemspec"
+
+inherit ruby-fakegem
+
+DESCRIPTION="Various middleware for Faraday"
+HOMEPAGE="https://github.com/lostisland/faraday_middleware"
+SRC_URI="https://github.com/lostisland/faraday_middleware/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="$(ver_cut 1)"
+KEYWORDS="~amd64"
+IUSE="brotli +parsexml +oauth +mashify +rashify"
+
+ruby_add_rdepend "
+ dev-ruby/faraday:1
+ brotli? ( dev-ruby/brotli )
+ parsexml? ( >=dev-ruby/multi_xml-0.5.3 )
+ oauth? ( >=dev-ruby/simple_oauth-0.1 )
+ mashify? ( >=dev-ruby/hashie-1.2:* )
+ rashify? ( >=dev-ruby/rash_alt-0.4.3 )"
+
+# Bundler must be used because the optional dependencies have different
+# version requirements that must be resolved.
+ruby_add_bdepend "test? (
+ >=dev-ruby/brotli-0.1.8
+ dev-ruby/bundler
+ >=dev-ruby/rake-12.3.3
+ dev-ruby/webmock:3
+ dev-ruby/json
+ >=dev-ruby/multi_xml-0.5.3
+ dev-ruby/rack:2.2
+ >=dev-ruby/rack-cache-1.1
+ >=dev-ruby/simple_oauth-0.1
+ >=dev-ruby/hashie-1.2
+ >=dev-ruby/rash_alt-0.4.3 )"
+
+all_ruby_prepare() {
+ sed -i -e '/\(cane\|parallel\|rubocop\|simplecov\)/ s:^:#:' \
+ -e "/addressable/ s/, '< 2.4'//" \
+ -e "/rack/ s/< 2/< 2.3/" \
+ -e "/rack-cache/ s/, '< 1.3'//" \
+ -e "/simple_oauth/ s/, '< 0.3'//" \
+ -e "/safe_yaml/ s:^:#:" \
+ -e "/webmock/ s/2.3/3.0/" Gemfile || die
+
+ # Avoid unneeded dependency on git
+ sed -i -e '/git ls-files/d' ${RUBY_FAKEGEM_GEMSPEC} || die
+
+ sed -i -e '1irequire "fileutils"' spec/spec_helper.rb || die
+
+ # Avoid safe_yaml specs since they are broken with newer ruby versions
+ # and safe_yaml is not mandatory for using faraday_middleware.
+ rm -f spec/unit/parse_yaml_spec.rb || die
+}
+
+each_ruby_test() {
+ ${RUBY} -S bundle exec rspec-3 spec || die
+}