%global pypi_name restsh Name: python-%{pypi_name} Version: 0.1 Release: 1%{?dist} Summary: A client for test and access to REST services License: BSD URL: https://github.com/jespino/restsh Source0: http://pypi.python.org/packages/source/r/restsh/restsh-0.1.tar.gz BuildArch: noarch BuildRequires: python-devel BuildRequires: python-setuptools BuildRequires: python-versiontools %description RestSH is a shell for easy test and use REST services. %prep %setup -q -n %{pypi_name}-%{version} # remove the bundled egg info rm -rf %{pypi_name}.egg-info %build %{__python} setup.py build %install %{__python} setup.py install -O1 --skip-build --root %{buildroot} # this file shouldn't be executable => strip shebang sed -i '1d' %{buildroot}%{python_sitelib}/%{pypi_name}lib/restshlib.py %files %{_bindir}/restsh %{python_sitelib}/%{pypi_name}lib %{python_sitelib}/%{pypi_name}-%{version}-py?.?.egg-info %changelog * Thu May 03 2012 Bohuslav Kabrda - 0.1-1 - Initial package.