summaryrefslogtreecommitdiff
blob: 98776673f64fbc40206a26e3d90e208cfa6f6922 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=5
USE_RUBY="ruby22 ruby23 ruby24"

RUBY_FAKEGEM_RECIPE_TEST="rspec"

RUBY_FAKEGEM_EXTRADOC="README.md WHATSNEW.md"
RUBY_FAKEGEM_RECIPE_DOC="rdoc"

inherit ruby-fakegem

DESCRIPTION="a cli tool (and module) to beautify ruby code"
HOMEPAGE="https://github.com/erniebrodeur/ruby-beautify"
LICENSE="MIT"

KEYWORDS="alpha amd64 arm ~hppa ia64 ppc ppc64 ~sparc x86"
SLOT="0"
IUSE=""

all_ruby_prepare() {
	sed -i -e '/codeclimate/I s:^:#:' spec/spec_helper.rb || die
}

each_ruby_prepare() {
	# Needed for specs
	mkdir tmp || die

	# Use correct ruby interpreter to test and avoid bundler. Handle
	# directory changes.
	sed -i -e 's|bundle exec|'${RUBY}' -Ilib:../lib -S|' spec/bin/ruby-beautify_spec.rb || die
}