[arch-commits] Commit in ruby-rack-test/repos (4 files)

Tim Meusel bastelfreak at archlinux.org
Wed Feb 24 18:45:59 UTC 2021


    Date: Wednesday, February 24, 2021 @ 18:45:59
  Author: bastelfreak
Revision: 871672

archrelease: copy trunk to community-testing-any

Added:
  ruby-rack-test/repos/community-testing-any/
  ruby-rack-test/repos/community-testing-any/PKGBUILD
    (from rev 871671, ruby-rack-test/trunk/PKGBUILD)
  ruby-rack-test/repos/community-testing-any/disable-rubocop.patch
    (from rev 871671, ruby-rack-test/trunk/disable-rubocop.patch)
  ruby-rack-test/repos/community-testing-any/disable-simplecov.patch
    (from rev 871671, ruby-rack-test/trunk/disable-simplecov.patch)

-------------------------+
 PKGBUILD                |   53 ++++++++++++++++++++++++++++++++++++++++++++++
 disable-rubocop.patch   |   20 +++++++++++++++++
 disable-simplecov.patch |   16 +++++++++++++
 3 files changed, 89 insertions(+)

Copied: ruby-rack-test/repos/community-testing-any/PKGBUILD (from rev 871671, ruby-rack-test/trunk/PKGBUILD)
===================================================================
--- community-testing-any/PKGBUILD	                        (rev 0)
+++ community-testing-any/PKGBUILD	2021-02-24 18:45:59 UTC (rev 871672)
@@ -0,0 +1,53 @@
+# Maintainer: Tim Meusel <tim at bastelfreak.de>
+
+_gemname='rack-test'
+pkgname="ruby-${_gemname}"
+pkgver=1.1.0
+pkgrel=1
+pkgdesc='small, simple testing API for Rack apps'
+arch=('any')
+url='https://github.com/rack/rack-test'
+license=('MIT')
+depends=('ruby' 'ruby-rack')
+makedepends=('ruby-rdoc' 'ruby-rake')
+checkdepends=('ruby-rspec')
+options=('!emptydirs')
+source=("${url}/archive/v${pkgver}/${_gemname}-v${pkgver}.tar.gz" 'disable-rubocop.patch' 'disable-simplecov.patch')
+sha512sums=('36d947d9b13d33ee8322e5b9d18fe8266787ccb7703f1fafadc040123e34dd44e98e7faf8b6dd816e51ed167065b2ffe79e9bcee74564dc324ba2b7dba76f82a'
+            'b1f09db04057846e7437b09a10ba38c792cbbbfd7c9fe938237d922ef72c02e0078f6a9542532b41b2f968680d539f766646995dce0a1d11ec7ab1673bc86490'
+            '5bc69c8b560bb4078e62db781698603f3f5a5722c8c1cf9912defed4862c42012db91945d852ff1ca14579f1d2b30a0978d523c35e366171542dc8afa7ef6280')
+
+prepare() {
+  cd "${srcdir}/${_gemname}-${pkgver}"
+  # allow latest dependencies
+  sed --in-place 's|~>|>=|g' "${_gemname}.gemspec"
+
+  # drop rubocop. We don't have it in the repos and it doesn't add any value during builds
+  patch -p1 -N -i "${srcdir}/disable-rubocop.patch"
+  # drop coverage reporting. We don't have simplecov in our repos
+  patch -p1 -N -i "${srcdir}/disable-simplecov.patch"
+
+}
+
+build() {
+  cd "${srcdir}/${_gemname}-${pkgver}"
+  gem build "${_gemname}.gemspec"
+}
+
+check() {
+  cd "${srcdir}/${_gemname}-${pkgver}"
+  # tests currently don't pass because we don't have sinatra in the repos
+  #rake spec
+}
+
+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 MIT-LICENSE.txt -t "${pkgdir}/usr/share/licenses/${pkgname}/"
+
+  install -Dm 644 README.md History.md -t "${pkgdir}/usr/share/doc/${pkgname}"
+
+  rm -rf "${pkgdir}/${_gemdir}/cache"
+}

Copied: ruby-rack-test/repos/community-testing-any/disable-rubocop.patch (from rev 871671, ruby-rack-test/trunk/disable-rubocop.patch)
===================================================================
--- community-testing-any/disable-rubocop.patch	                        (rev 0)
+++ community-testing-any/disable-rubocop.patch	2021-02-24 18:45:59 UTC (rev 871672)
@@ -0,0 +1,20 @@
+diff --git a/Rakefile b/Rakefile
+index 93b70fe..daad2ce 100644
+--- a/Rakefile
++++ b/Rakefile
+@@ -1,5 +1,3 @@
+-require 'rubygems'
+-
+ require 'rspec/core'
+ require 'rspec/core/rake_task'
+ 
+@@ -10,9 +8,6 @@ RSpec::Core::RakeTask.new do |t|
+   t.ruby_opts = '-w'
+ end
+ 
+-require 'rubocop/rake_task'
+-RuboCop::RakeTask.new
+-
+ desc 'Generate RDoc'
+ task :docs do
+   FileUtils.rm_rf('doc')

Copied: ruby-rack-test/repos/community-testing-any/disable-simplecov.patch (from rev 871671, ruby-rack-test/trunk/disable-simplecov.patch)
===================================================================
--- community-testing-any/disable-simplecov.patch	                        (rev 0)
+++ community-testing-any/disable-simplecov.patch	2021-02-24 18:45:59 UTC (rev 871672)
@@ -0,0 +1,16 @@
+diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
+index 9cebd4b..00e34d5 100644
+--- a/spec/spec_helper.rb
++++ b/spec/spec_helper.rb
+@@ -1,11 +1,3 @@
+-require 'simplecov'
+-SimpleCov.start do
+-  add_filter '/spec/'
+-end
+-
+-require 'rubygems'
+-require 'bundler/setup'
+-
+ require 'rack'
+ require 'rspec'
+ 


More information about the arch-commits mailing list