| |
@@ -2,20 +2,18 @@
|
| |
%global gem_name pundit
|
| |
|
| |
Name: rubygem-%{gem_name}
|
| |
- Version: 1.0.1
|
| |
- Release: 6%{?dist}
|
| |
+ Version: 2.0.1
|
| |
+ Release: 1%{?dist}
|
| |
Summary: Object oriented authorization for Rails
|
| |
- Group: Development/Languages
|
| |
License: MIT
|
| |
- URL: https://github.com/elabs/pundit
|
| |
+ URL: https://github.com/varvet/pundit
|
| |
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
| |
BuildRequires: ruby(release)
|
| |
BuildRequires: rubygems-devel
|
| |
BuildRequires: ruby
|
| |
- BuildRequires: rubygem(activemodel) >= 3.0.0
|
| |
- BuildRequires: rubygem(actionpack) >= 3.0.0
|
| |
- BuildRequires: rubygem(rspec) => 2.0
|
| |
- BuildRequires: rubygem(rspec) < 3.1
|
| |
+ BuildRequires: rubygem(activemodel)
|
| |
+ BuildRequires: rubygem(actionpack)
|
| |
+ BuildRequires: rubygem(rspec)
|
| |
BuildArch: noarch
|
| |
|
| |
%description
|
| |
@@ -24,7 +22,6 @@
|
| |
|
| |
%package doc
|
| |
Summary: Documentation for %{name}
|
| |
- Group: Documentation
|
| |
Requires: %{name} = %{version}-%{release}
|
| |
BuildArch: noarch
|
| |
|
| |
@@ -32,14 +29,10 @@
|
| |
Documentation for %{name}.
|
| |
|
| |
%prep
|
| |
- gem unpack %{SOURCE0}
|
| |
-
|
| |
- %setup -q -D -T -n %{gem_name}-%{version}
|
| |
-
|
| |
- gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
|
| |
+ %setup -q -n %{gem_name}-%{version}
|
| |
|
| |
%build
|
| |
- gem build %{gem_name}.gemspec
|
| |
+ gem build ../%{gem_name}-%{version}.gemspec
|
| |
%gem_install
|
| |
|
| |
%install
|
| |
@@ -47,22 +40,18 @@
|
| |
cp -a .%{gem_dir}/* \
|
| |
%{buildroot}%{gem_dir}/
|
| |
|
| |
- # Fix permissions
|
| |
- chmod a-x %{buildroot}%{gem_instdir}/lib/generators/pundit/policy/templates/policy.rb
|
| |
-
|
| |
%check
|
| |
|
| |
# We don't need pry
|
| |
- sed -i '6d' spec/spec_helper.rb
|
| |
- rspec2 spec
|
| |
+ sed -i '/require "pry"/ s/^/#/' spec/spec_helper.rb
|
| |
+ rspec spec
|
| |
|
| |
%files
|
| |
%dir %{gem_instdir}
|
| |
%{gem_libdir}
|
| |
%exclude %{gem_cache}
|
| |
- %exclude %{gem_instdir}/.travis.yml
|
| |
- %exclude %{gem_instdir}/.gitignore
|
| |
- %doc %{gem_instdir}/LICENSE.txt
|
| |
+ %exclude %{gem_instdir}/.*
|
| |
+ %license %{gem_instdir}/LICENSE.txt
|
| |
%{gem_spec}
|
| |
|
| |
%files doc
|
| |
@@ -77,6 +66,9 @@
|
| |
%{gem_instdir}/spec
|
| |
|
| |
%changelog
|
| |
+ * Fri Jan 18 2019 Pavel Valena <pvalena@redhat.com> - 2.0.1-1
|
| |
+ - Update to Pundit 2.0.1.
|
| |
+
|
| |
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.0.1-6
|
| |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
| |
|
| |
also enhance .spec and .gitignore files.
Builds fine with Ruby 2.6 - Copr build:
https://copr.fedorainfracloud.org/coprs/build/847936/
Checks: