forked from pool/python-sh
OBS-URL: https://build.opensuse.org/request/show/220377 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-sh?expand=0&rev=1
68 lines
1.9 KiB
RPMSpec
68 lines
1.9 KiB
RPMSpec
#
|
|
# spec file for package
|
|
#
|
|
# Copyright (c) 2014 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: python-sh
|
|
Version: 1.08
|
|
Release: 0
|
|
License: MIT
|
|
Summary: Python subprocess interface
|
|
Url: https://github.com/amoffat/sh
|
|
Group: Development/Languages/Python
|
|
Source0: https://github.com/amoffat/sh/archive/%{version}.tar.gz
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
BuildArch: noarch
|
|
|
|
BuildRequires: python-devel
|
|
BuildRequires: python-setuptools
|
|
|
|
%description
|
|
sh (previously pbs) is a full-fledged subprocess
|
|
replacement for Python 2.6 - 3.2 that allows you to call
|
|
any program as if it were a function:
|
|
|
|
from sh import ifconfig
|
|
print ifconfig("eth0")
|
|
|
|
sh is not a collection of system commands implemented in
|
|
Python.
|
|
|
|
%prep
|
|
%setup -q -n sh-%{version}
|
|
|
|
%build
|
|
python setup.py build
|
|
|
|
%install
|
|
python setup.py install \
|
|
--prefix=%{_prefix} \
|
|
--root=%{buildroot}
|
|
|
|
# mvyskocil: FIXME, fails on test_non_ascii_error and test_unicode_arg
|
|
# with UnicodeEncodeError/UnicodeDecodeError
|
|
# % check
|
|
# python test.py
|
|
|
|
%files
|
|
%defattr(0644,root,root)
|
|
%doc AUTHORS.md CHANGELOG.md LICENSE.txt README.md
|
|
%{python_sitelib}/sh.py
|
|
%{python_sitelib}/sh.pyc
|
|
%{python_sitelib}/sh-%{version}-*.egg-info
|
|
|
|
%changelog
|
|
|