File gnome-shell-search-provider-openSUSE-packages.spec of Package gnome-shell-search-provider-openSUSE-packages

#
# spec file for package gnome-shell-search-provider-openSUSE-packages
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

Name:           gnome-shell-search-provider-openSUSE-packages
Version:        0.2
Release:        1
License:        BSD3c
Summary:        Search Provider to look for openSUSE packages in GNOME Shell
Group:          System/GUI/GNOME
Url:            http://software.opensuse.org/
Source0:        packages.xml.in
BuildRequires:  gnome-shell
BuildRequires:  lsb-release
BuildRequires:  openSUSE-release
Requires:       gnome-shell
Provides:       gnome-shell-extension-openSUSE-package-search = %{version}
Obsoletes:      gnome-shell-extension-openSUSE-package-search < %{version}
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch

%description
This package adds a search provider to search for packages on the
openSUSE Build service repositories in the GNOME Shell overview.

%prep
%setup -c -T
cp %{SOURCE0} .

%build
suse_dist_version=$(lsb_release -rs)
sed "s/_suseversion_/$suse_dist_version/" packages.xml.in > packages.xml

%install
mkdir -p %{buildroot}%{_datadir}/gnome-shell/search_providers/
install -m 0644 packages.xml %{buildroot}%{_datadir}/gnome-shell/search_providers/

%files
%defattr(-,root,root)
%{_datadir}/gnome-shell/search_providers/packages.xml

%changelog
openSUSE Build Service is sponsored by