diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..74e36f8 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/Send2Trash-1.4.2.tar.gz diff --git a/python-send2trash.spec b/python-send2trash.spec new file mode 100644 index 0000000..ea7386d --- /dev/null +++ b/python-send2trash.spec @@ -0,0 +1,83 @@ +%global pypiname Send2Trash + +Name: python-send2trash +Version: 1.4.2 +Release: 2%{?dist} +Summary: Python library to natively send files to Trash + +License: BSD +URL: https://github.com/hsoft/send2trash +Source0: https://files.pythonhosted.org/packages/source/s/send2trash/%{pypiname}-%{version}.tar.gz + +BuildArch: noarch +BuildRequires: python2-devel +BuildRequires: python3-devel + +%description +Send2Trash is a small package that sends files to the Trash (or Recycle Bin) +natively and on all platforms. On OS X, it uses native FSMoveObjectToTrashSync +Cocoa calls, on Windows, it uses native (and ugly) SHFileOperation win32 calls. +On other platforms, if PyGObject and GIO are available, it will use this. +Otherwise, it will fallback to its own implementation of the trash specifications +from freedesktop.org. + +%package -n python2-send2trash + +Summary: Python library to natively send files to Trash + +%{?python_provide:%python_provide python2-%{pypiname}} +%{?python_provide:%python_provide python2-%send2trash} + +%description -n python2-send2trash +Send2Trash is a small package that sends files to the Trash (or Recycle Bin) +natively and on all platforms. On OS X, it uses native FSMoveObjectToTrashSync +Cocoa calls, on Windows, it uses native (and ugly) SHFileOperation win32 calls. +On other platforms, if PyGObject and GIO are available, it will use this. +Otherwise, it will fallback to its own implementation of the trash specifications +from freedesktop.org. + +%package -n python3-send2trash + +Summary: Python library to natively send files to Trash + +%{?python_provide:%python_provide python3-%{pypiname}} +%{?python_provide:%python_provide python3-send2trash} + +%description -n python3-send2trash +Send2Trash is a small package that sends files to the Trash (or Recycle Bin) +natively and on all platforms. On OS X, it uses native FSMoveObjectToTrashSync +Cocoa calls, on Windows, it uses native (and ugly) SHFileOperation win32 calls. +On other platforms, if PyGObject and GIO are available, it will use this. +Otherwise, it will fallback to its own implementation of the trash specifications +from freedesktop.org. + +%prep +%setup -q -n %{pypiname}-%{version} + +%build +%py2_build +%py3_build + +%install +%py2_install +%py3_install + + +%files -n python2-send2trash +%doc README.rst CHANGES.rst +%{python2_sitelib}/send2trash* +%{python2_sitelib}/%{pypiname}* + +%files -n python3-send2trash +%doc README.rst CHANGES.rst +%{python3_sitelib}/send2trash* +%{python3_sitelib}/%{pypiname}* + +%changelog +* Sat Jan 06 2018 williamjmorenor@gmail.com - 1.4.2-2 +- Initial import of BZ#1529027 + +* Tue Dec 26 2017 williamjmorenor@gmail.com - 1.4.2-1 +- Initial Packaging + + diff --git a/sources b/sources new file mode 100644 index 0000000..df890b6 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (Send2Trash-1.4.2.tar.gz) = 6f9eb835a3a55b892dd14a07a685b8f13f3fea482e2b61f66b92652eeb1e7adcbcf0873d087419f15acbb5fbc1d7cc275b0f2872146b21c7f23064df58418aae