[arch-commits] Commit in ruby-webmock (4 files)

Tim Meusel bastelfreak at archlinux.org
Sun May 16 19:58:07 UTC 2021


    Date: Sunday, May 16, 2021 @ 19:58:06
  Author: bastelfreak
Revision: 935951

archrelease: copy trunk to community-any

Added:
  ruby-webmock/repos/
  ruby-webmock/repos/community-any/
  ruby-webmock/repos/community-any/PKGBUILD
    (from rev 935950, ruby-webmock/trunk/PKGBUILD)
  ruby-webmock/repos/community-any/disable-unneeded-dependencies.patch
    (from rev 935950, ruby-webmock/trunk/disable-unneeded-dependencies.patch)

-------------------------------------+
 PKGBUILD                            |   56 ++++++++++++++++++++++++++++++++++
 disable-unneeded-dependencies.patch |   19 +++++++++++
 2 files changed, 75 insertions(+)

Copied: ruby-webmock/repos/community-any/PKGBUILD (from rev 935950, ruby-webmock/trunk/PKGBUILD)
===================================================================
--- repos/community-any/PKGBUILD	                        (rev 0)
+++ repos/community-any/PKGBUILD	2021-05-16 19:58:06 UTC (rev 935951)
@@ -0,0 +1,56 @@
+# Maintainer: Tim Meusel <tim at bastelfreak.de>
+# Contributor: Christian Rebischke <chris.rebischke at archlinux.org>
+
+_gemname='webmock'
+pkgname="ruby-${_gemname}"
+pkgver=3.13.0
+pkgrel=1
+pkgdesc='Allows stubbing HTTP requests and setting expectations on HTTP requests.'
+arch=('any')
+url='https://github.com/bblimke/webmock'
+license=('MIT')
+makedepends=('ruby-rdoc')
+checkdepends=('ruby-rake' 'ruby-minitest' 'ruby-test-unit' 'ruby-rspec')
+depends=('ruby' 'ruby-crack' 'ruby-hashdiff' 'ruby-addressable')
+options=(!emptydirs)
+source=("${url}/archive/v${pkgver}/${pkgname}-v${pkgver}.tar.gz"
+        'disable-unneeded-dependencies.patch')
+sha512sums=('aab53f941af5e7f2b099b8f00ce6727acf841f943f28b54ae40415752aa289e87a6867d2c5ab2568b7055f9edd33679bb51408d543202cd5e6a3525d9c77c839'
+            'd946429e8f4f90ef263e8b28b4b536b2d81a46f48076a64f5a68ea06fa9abb19470c9bd14035d086d8e054b0df9085f5793b1aa38ffda576b5161852ddae64aa')
+
+prepare() {
+  cd "${srcdir}/${_gemname}-${pkgver}"
+
+  # we build based on a tar ball, so `git` won't work
+  sed --in-place 's|git ls-files|find|' "${_gemname}.gemspec" spec/quality_spec.rb
+
+  # disable unneeded dependencies
+  patch --forward --verbose --strip=1 --input='../disable-unneeded-dependencies.patch'
+  sed --in-place '/bundler/d' Rakefile
+  sed --in-place '/Bundler/d' Rakefile
+}
+
+build() {
+  cd "${srcdir}/${_gemname}-${pkgver}"
+  gem build "${_gemname}.gemspec"
+}
+
+check() {
+  cd "${srcdir}/${_gemname}-${pkgver}"
+  rake minitest
+  rake test
+
+}
+
+package() {
+  cd "${srcdir}/${_gemname}-${pkgver}"
+  local _gemdir="$(gem env gemdir)"
+  gem install --verbose --ignore-dependencies --no-user-install --install-dir "${pkgdir}/${_gemdir}" --bindir "${pkgdir}/usr/bin" "${_gemname}-${pkgver}.gem"
+
+  install -Dm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}/"
+
+  rm -rf "${pkgdir}/${_gemdir}/cache"
+  rm -rf "${pkgdir}/${_gemdir}/gems/${_gemname}-${pkgver}/"{test,spec,minitest,.gemtest,.gitignore,.travis.yml}
+}
+
+# vim: ts=2 sw=2 et:

Copied: ruby-webmock/repos/community-any/disable-unneeded-dependencies.patch (from rev 935950, ruby-webmock/trunk/disable-unneeded-dependencies.patch)
===================================================================
--- repos/community-any/disable-unneeded-dependencies.patch	                        (rev 0)
+++ repos/community-any/disable-unneeded-dependencies.patch	2021-05-16 19:58:06 UTC (rev 935951)
@@ -0,0 +1,19 @@
+diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
+index 7a219fc..cfe0c53 100644
+--- a/spec/spec_helper.rb
++++ b/spec/spec_helper.rb
+@@ -1,14 +1,5 @@
+ require 'rubygems'
+ require 'httpclient'
+-unless RUBY_PLATFORM =~ /java/
+-  require 'curb'
+-  require 'patron'
+-  require 'em-http'
+-  require 'typhoeus'
+-end
+-if RUBY_PLATFORM =~ /java/
+-  require 'manticore'
+-end
+ 
+ $LOAD_PATH.unshift(File.dirname(__FILE__))
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))



More information about the arch-commits mailing list