Gentoo Archives: gentoo-commits

From: Hans de Graaff <graaff@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ruby/listen/, dev-ruby/listen/files/
Date: Fri, 18 Jan 2019 08:23:57
Message-Id: 1547799818.9ea316fd37f824fb9ff3987a54b57c1452afc2a3.graaff@gentoo
1 commit: 9ea316fd37f824fb9ff3987a54b57c1452afc2a3
2 Author: Hans de Graaff <graaff <AT> gentoo <DOT> org>
3 AuthorDate: Fri Jan 18 08:22:39 2019 +0000
4 Commit: Hans de Graaff <graaff <AT> gentoo <DOT> org>
5 CommitDate: Fri Jan 18 08:23:38 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9ea316fd
7
8 dev-ruby/listen: add ruby26 revision
9
10 Signed-off-by: Hans de Graaff <graaff <AT> gentoo.org>
11 Package-Manager: Portage-2.3.51, Repoman-2.3.11
12
13 dev-ruby/listen/files/listen-3.1.5-ruby26.patch | 33 +++++++++++++++++
14 dev-ruby/listen/listen-3.1.5-r3.ebuild | 49 +++++++++++++++++++++++++
15 2 files changed, 82 insertions(+)
16
17 diff --git a/dev-ruby/listen/files/listen-3.1.5-ruby26.patch b/dev-ruby/listen/files/listen-3.1.5-ruby26.patch
18 new file mode 100644
19 index 00000000000..f90ab1ed213
20 --- /dev/null
21 +++ b/dev-ruby/listen/files/listen-3.1.5-ruby26.patch
22 @@ -0,0 +1,33 @@
23 +From 2908365366792ac3ba010fa32bc3be2beaed451a Mon Sep 17 00:00:00 2001
24 +From: Samuel Williams <samuel.williams@××××××××××××××××.nz>
25 +Date: Sun, 16 Dec 2018 11:32:45 +1300
26 +Subject: [PATCH] Use raw Pathname to fix Linux specs.
27 +
28 +---
29 + lib/listen/adapter/linux.rb | 2 +-
30 + spec/lib/listen/adapter/linux_spec.rb | 12 +-----------
31 + 2 files changed, 2 insertions(+), 12 deletions(-)
32 +
33 +diff --git a/spec/lib/listen/adapter/linux_spec.rb b/spec/lib/listen/adapter/linux_spec.rb
34 +index d77f0c0..da48319 100644
35 +--- a/spec/lib/listen/adapter/linux_spec.rb
36 ++++ b/spec/lib/listen/adapter/linux_spec.rb
37 +@@ -10,17 +10,7 @@
38 + end
39 +
40 + if linux?
41 +- let(:dir1) do
42 +- instance_double(
43 +- Pathname,
44 +- 'dir1',
45 +- to_s: '/foo/dir1',
46 +- cleanpath: real_dir1
47 +- )
48 +- end
49 +-
50 +- # just so cleanpath works in above double
51 +- let(:real_dir1) { instance_double(Pathname, 'dir1', to_s: '/foo/dir1') }
52 ++ let(:dir1) {Pathname.new("/foo/dir1")}
53 +
54 + let(:config) { instance_double(Listen::Adapter::Config) }
55 + let(:queue) { instance_double(Queue) }
56
57 diff --git a/dev-ruby/listen/listen-3.1.5-r3.ebuild b/dev-ruby/listen/listen-3.1.5-r3.ebuild
58 new file mode 100644
59 index 00000000000..b34298d01ef
60 --- /dev/null
61 +++ b/dev-ruby/listen/listen-3.1.5-r3.ebuild
62 @@ -0,0 +1,49 @@
63 +# Copyright 1999-2019 Gentoo Authors
64 +# Distributed under the terms of the GNU General Public License v2
65 +
66 +EAPI=6
67 +
68 +USE_RUBY="ruby23 ruby24 ruby25 ruby26"
69 +
70 +RUBY_FAKEGEM_RECIPE_TEST="rspec3"
71 +
72 +RUBY_FAKEGEM_TASK_DOC=""
73 +RUBY_FAKEGEM_EXTRADOC="CHANGELOG.md README.md"
74 +
75 +RUBY_FAKEGEM_GEMSPEC="${PN}.gemspec"
76 +
77 +inherit ruby-fakegem
78 +
79 +SRC_URI="https://github.com/guard/listen/archive/v${PV}.tar.gz -> ${P}.tar.gz"
80 +DESCRIPTION="Listens to file modifications and notifies you about the changes"
81 +HOMEPAGE="https://github.com/guard/listen"
82 +
83 +LICENSE="MIT"
84 +SLOT="3"
85 +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~x86"
86 +IUSE="test"
87 +
88 +# Block on other packages trying to install a /usr/bin/listen
89 +RDEPEND+="!!media-radio/ax25-apps !!<dev-ruby/listen-2.8.6-r1:2"
90 +
91 +ruby_add_rdepend ">=dev-ruby/rb-inotify-0.9.7 >=dev-ruby/ruby_dep-1.2:1"
92 +
93 +ruby_add_bdepend "test? ( dev-ruby/thor )"
94 +
95 +PATCHES=( "${FILESDIR}/${P}-ruby26.patch" )
96 +
97 +all_ruby_prepare() {
98 + rm -f Gemfile || die
99 + sed -i -e "/git/,+3d" -e "/rb-fsevent/d" ${PN}.gemspec || die
100 + sed -i -e "/rb-fsevent/d" lib/listen/adapter/darwin.rb || die
101 + rm -rf spec/lib/listen/adapter/darwin_spec.rb || die
102 +}
103 +
104 +each_ruby_prepare() {
105 + mkdir spec/.fixtures || die
106 +}
107 +
108 +each_ruby_test() {
109 + RSPEC_VERSION=3 ruby-ng_rspec
110 + rm -rf spec/.fixtures || die
111 +}