dd28575
%global gem_name scoped_search
dd28575
dd28575
Summary: Easily search your ActiveRecord models
dd28575
Name: rubygem-%{gem_name}
dd28575
08c6ea2
Version: 4.1.0
61975c6
Release: 4%{?dist}
dd28575
Group: Development/Languages
dd28575
License: MIT
528976a
URL: https://github.com/wvanbergen/scoped_search/wiki
dd28575
Source0: https://rubygems.org/downloads/%{gem_name}-%{version}.gem
dd28575
BuildRequires: rubygems-devel
dd28575
BuildArch: noarch
dd28575
dd28575
# for check section
Dominic Cleal 405d401
BuildRequires: rubygem(rspec) >= 3.0
Dominic Cleal 405d401
BuildRequires: rubygem(rspec) < 4.0
528976a
BuildRequires: rubygem(activerecord) >= 4.2.0
08c6ea2
BuildRequires: rubygem(actionview) >= 4.2.0
dd28575
BuildRequires: rubygem(sqlite3)
dd28575
dd28575
%description
dd28575
Scoped search makes it easy to search your ActiveRecord-based models. It will
dd28575
create a named scope :search_for that can be called with a query string. It
dd28575
will build an SQL query using the provided query string and a definition that
dd28575
specifies on what fields to search. Because the functionality is built on
dd28575
named_scope, the result of the search_for call can be used like any other
dd28575
named_scope, so it can be chained with another scope or combined with
dd28575
will_paginate. Because it uses standard SQL, it does not require any setup,
dd28575
indexers or daemons. This makes scoped_search suitable to quickly add basic
dd28575
search functionality to your application with little hassle. On the other hand,
dd28575
it may not be the best choice if it is going to be used on very large data sets
dd28575
or by a large user base.
dd28575
dd28575
%package doc
dd28575
BuildArch:  noarch
dd28575
Requires:   %{name} = %{version}-%{release}
dd28575
Summary:    Documentation for rubygem-%{gem_name}
dd28575
dd28575
%description doc
dd28575
This package contains documentation for rubygem-%{gem_name}.
dd28575
dd28575
dd28575
%prep
dd28575
gem unpack %{SOURCE0}
dd28575
%setup -q -D -T -n  %{gem_name}-%{version}
dd28575
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
dd28575
dd28575
%build
dd28575
dd28575
# Create the gem as gem install only works on a gem file
dd28575
gem build %{gem_name}.gemspec
dd28575
80c6304
%gem_install
dd28575
dd28575
%install
dd28575
mkdir -p %{buildroot}%{gem_dir}
dd28575
cp -a ./%{gem_dir}/* %{buildroot}%{gem_dir}/
Dominic Cleal 405d401
mv %{buildroot}%{gem_instdir}/{LICENSE,*.rdoc} ./
dd28575
dd28575
%check
dd28575
pushd .%{gem_instdir}
dd28575
# Get rid of Bundler, not needed on Fedora.
dd28575
sed -i "/require 'bundler\/setup'/ d" spec/spec_helper.rb
528976a
EXCLUDE_DATABASE=mysql,postgresql rspec spec
dd28575
popd
dd28575
dd28575
%files
dd28575
%doc LICENSE
dd28575
%dir %{gem_instdir}
dd28575
%{gem_instdir}/lib
def4c10
%{gem_instdir}/app
dd28575
%{gem_spec}
Dominic Cleal 405d401
%exclude %{gem_cache}
Dominic Cleal 405d401
%exclude %{gem_instdir}/.*
dd28575
dd28575
%files doc
dd28575
%doc %{gem_docdir}
Dominic Cleal 405d401
%doc CHANGELOG.rdoc CONTRIBUTING.rdoc README.rdoc
dd28575
%{gem_instdir}/Rakefile
dd28575
%{gem_instdir}/Gemfile*
dd28575
%{gem_instdir}/spec
dd28575
%{gem_instdir}/%{gem_name}.gemspec
dd28575
dd28575
%changelog
61975c6
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 4.1.0-4
61975c6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
61975c6
9576f74
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 4.1.0-3
9576f74
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
9576f74
a25c38c
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 4.1.0-2
a25c38c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
a25c38c
08c6ea2
* Wed Mar 29 2017 Dominic Cleal <dominic@cleal.org> - 4.1.0-1
08c6ea2
- rebase to scoped_search 4.1.0
08c6ea2
a3b0d3d
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 4.0.0-2
a3b0d3d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
a3b0d3d
6c7071f
* Mon Dec 05 2016 Dominic Cleal <dominic@cleal.org> - 4.0.0-1
6c7071f
- rebase to scoped_search 4.0.0
6c7071f
04b6068
* Tue Aug 09 2016 Dominic Cleal <dominic@cleal.org> - 3.3.0-1
04b6068
- rebase to scoped_search 3.3.0
04b6068
b1344c9
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.2.2-2
b1344c9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
b1344c9
Dominic Cleal c1435bd
* Tue Jul 28 2015 Dominic Cleal <dcleal@redhat.com> - 3.2.2-1
Dominic Cleal c1435bd
- rebase to scoped_search 3.2.2
Dominic Cleal c1435bd
Dominic Cleal 405d401
* Wed Jun 24 2015 Dominic Cleal <dcleal@redhat.com> - 3.2.1-1
Dominic Cleal 405d401
- rebase to scoped_search 3.2.1
Dominic Cleal 405d401
- remove patches for earlier Rails 4.1 compatibility
Dominic Cleal 405d401
9d0292f
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.7.1-4
9d0292f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
9d0292f
Dominic Cleal 826a09a
* Mon Nov 10 2014 Dominic Cleal <dcleal@redhat.com> - 2.7.1-3
Dominic Cleal 826a09a
- fix Rails 4.1 compatibility (BZ#1107234)
Dominic Cleal 29e34cc
- use RSpec2 on Fedora 22 or above
Dominic Cleal 826a09a
2431de0
* Sun Jun 08 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.7.1-2
2431de0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
2431de0
4246f62
* Mon Mar 31 2014 Miroslav Suchý <msuchy@redhat.com> 2.7.1-1
4246f62
- rebase to scoped_search 2.7.1
4246f62
92d74c3
* Thu Feb 13 2014 Miroslav Suchý <msuchy@redhat.com> 2.6.3-1
92d74c3
- rebase to scoped_search-2.6.3
92d74c3
6d0d2c9
* Tue Feb 11 2014 Miroslav Suchý <msuchy@redhat.com> 2.6.2-1
6d0d2c9
- rebase to scoped_search-2.6.2
6d0d2c9
4017bf5
* Wed Dec 18 2013 Miroslav Suchý <msuchy@redhat.com> 2.6.1-1
4017bf5
- rebase to scoped_search-2.6.1
4017bf5
6763b24
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.6.0-2
6763b24
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
6763b24
b6e3fb7
* Thu Jun 20 2013 Miroslav Suchý <msuchy@redhat.com> 2.6.0-1
b6e3fb7
- rebase to 2.6.0 release (msuchy@redhat.com)
b6e3fb7
def4c10
* Wed Apr 03 2013 Miroslav Suchý <msuchy@redhat.com> 2.5.1-1
def4c10
- rebase to 2.5.1
def4c10
b054ca2
* Tue Apr 02 2013 Miroslav Suchý <msuchy@redhat.com> 2.5.0-1
b054ca2
- rebase to 2.5.0
b054ca2
80c6304
* Wed Mar 13 2013 Miroslav Suchý <msuchy@redhat.com> - 2.4.1-2
80c6304
- Rebuild for https://fedoraproject.org/wiki/Features/Ruby_2.0.0
80c6304
03934ed
* Mon Mar 11 2013 Miroslav Suchý <msuchy@redhat.com> 2.4.1-1
03934ed
- rebase to 2.4.1
03934ed
9d6c4c8
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.4.0-6
9d6c4c8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
9d6c4c8
dd28575
* Mon Dec 03 2012 Miroslav Suchý <msuchy@redhat.com> 2.4.0-5
dd28575
- run test only on F18+ (msuchy@redhat.com)
dd28575
- enable tests (msuchy@redhat.com)
dd28575
dd28575
* Tue Oct 30 2012 Miroslav Suchý <msuchy@redhat.com> 2.4.0-4
dd28575
- do not run test on rhel6 at all due missing rspec (msuchy@redhat.com)
dd28575
dd28575
* Tue Oct 30 2012 Miroslav Suchý <msuchy@redhat.com> 2.4.0-3
dd28575
- remove .travis.yml, add Gemfile.activerecord* (msuchy@redhat.com)
dd28575
dd28575
* Mon Oct 29 2012 Miroslav Suchý <msuchy@redhat.com> 2.4.0-2
dd28575
- do not run test, because it is not working (msuchy@redhat.com)
dd28575
- disable testing on other backend but sqllite (msuchy@redhat.com)
dd28575
- update to recent scoped_search-2.4.0.gem (msuchy@redhat.com)
dd28575
dd28575
* Tue Oct 16 2012 Miroslav Suchý <msuchy@redhat.com> 2.4.0-1
dd28575
- update to recent scoped_search-2.4.0.gem (msuchy@redhat.com)
dd28575
dd28575
* Wed Aug 15 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-10
dd28575
- 847504 - move gemspec to -doc subpackage (msuchy@redhat.com)
dd28575
dd28575
* Wed Aug 15 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-9
dd28575
- test suite is failing on F17 a lot - disable for now (msuchy@redhat.com)
dd28575
- 847504 - use test suite (msuchy@redhat.com)
dd28575
- 847504 - remove dot files in %%install section (msuchy@redhat.com)
dd28575
- 847504 - use macro in SOURCE0 (msuchy@redhat.com)
dd28575
dd28575
* Tue Aug 14 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-8
dd28575
- 847504 - put in front of chmod link to github issue (msuchy@redhat.com)
dd28575
- 847504 - fix typo in summary (msuchy@redhat.com)
dd28575
dd28575
* Tue Aug 14 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-7
dd28575
- 847504 - remove cached gem (msuchy@redhat.com)
dd28575
- 847504 - correctly use dist tag (msuchy@redhat.com)
dd28575
- 847504 - rewrap description (msuchy@redhat.com)
dd28575
dd28575
* Sun Aug 12 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-6
dd28575
- fix spelling error (msuchy@redhat.com)
dd28575
- module scoped_search.rb should not be executable (msuchy@redhat.com)
dd28575
dd28575
* Sun Aug 12 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-5
dd28575
- buildroot is not needed (msuchy@redhat.com)
dd28575
- change Group to valid item (msuchy@redhat.com)
dd28575
dd28575
* Fri Aug 10 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-4
dd28575
- there is no need to require rubygems in some version (msuchy@redhat.com)
dd28575
dd28575
* Fri Aug 10 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-3
dd28575
- there is no need to require rubygems in some version (msuchy@redhat.com)
dd28575
dd28575
* Thu Aug 09 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-2
dd28575
- fix filelist (msuchy@redhat.com)
dd28575
- create doc subpackage (msuchy@redhat.com)
dd28575
- fix requirements (msuchy@redhat.com)
dd28575
dd28575
* Thu Aug 09 2012 Miroslav Suchý <msuchy@redhat.com> 2.3.7-1
dd28575
- edit rubygem-scoped_search.spec according guidelines (msuchy@redhat.com)
dd28575
- import rubygem-scoped_search.spec from foreman-rpms (msuchy@redhat.com)
dd28575