[python-di/f17] inital commit

Martin Sivák msivak at fedoraproject.org
Mon Dec 17 15:18:53 UTC 2012


commit fe3a49c723aa280b53752e7876a1fe9f0da965a3
Author: Martin Sivak <msivak at redhat.com>
Date:   Mon Dec 17 16:17:29 2012 +0100

    inital commit

 .gitignore     |    1 +
 python-di.spec |   60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 sources        |    1 +
 3 files changed, 62 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..ad8e1f7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/di-0.2.tar.gz
diff --git a/python-di.spec b/python-di.spec
new file mode 100644
index 0000000..f22e307
--- /dev/null
+++ b/python-di.spec
@@ -0,0 +1,60 @@
+%if 0%{?rhel} && 0%{?rhel} <= 5
+%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
+%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
+%endif
+
+Name:           python-di
+Version:        0.2
+Release:        1%{?dist}
+Summary:        Python library for dependency injection support
+
+License:        GPLv2+
+URL:            http://fedorapeople.org/cgit/msivak/public_git/python-di.git/
+
+# get the current source file using the following two commands
+# git clone git://fedorapeople.org/home/fedora/msivak/public_git/python-di.git
+# cd python-di; python setup.py sdist
+# it will be in the dist directory
+Source0:        http://pypi.python.org/packages/source/d/di/di-%{version}.tar.gz
+
+BuildRequires:  python-setuptools-devel
+BuildRequires:  python-nose
+BuildRequires:  python2-devel     
+BuildArch:      noarch
+
+%description
+This python package provides a "di" module. The module contains a couple of
+decorators which try to implement the Dependency Injection (IoC) pattern
+without requiring the user to change local variables in his methods.
+
+It is intended to be used in unit testing environments.
+
+%prep
+%setup -q -n di-%{version}
+
+# remove upstream egg-info
+rm -rf *.egg-info
+
+%build
+%{__python} setup.py build
+
+%install
+%{__python} setup.py install --skip-build --root $RPM_BUILD_ROOT
+rm -rf ${buildroot}%{python_sitelib}/setuptools/tests
+
+%check
+%{__python} setup.py nosetests
+
+%files
+%{python_sitelib}/di
+%{python_sitelib}/di-*.egg-info
+
+%doc README COPYING
+
+%changelog
+* Thu Dec  6 2012 Martin Sivak <msivak at euryale.brq.redhat.com> - 0.2-1
+- DiRegistry support for accessing attributes of the decorated object
+
+* Fri Nov 23 2012 Martin Sivak <msivak at euryale.brq.redhat.com> - 0.1-1
+- Inital release
+
diff --git a/sources b/sources
index e69de29..2554b3e 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+bb4390af7a4ad8ae6c6aaf70a084fc67  di-0.2.tar.gz


More information about the scm-commits mailing list