From d06fe1f2dee3a8331cf4e0fd6a7223bb65127376 Mon Sep 17 00:00:00 2001 From: Ed Bartosh Date: Sun, 1 Feb 2015 14:27:13 +0200 Subject: [PATCH] Add rpm packaging Fixes: #2387 Change-Id: Ib0898f8efdbf23f8bed4bbc4c8b097da412713ce Signed-off-by: Ed Bartosh --- packaging/python-jenkinsapi.changes | 144 ++++++++++++++++++++++++++++++++++++ packaging/python-jenkinsapi.spec | 79 ++++++++++++++++++++ 2 files changed, 223 insertions(+) create mode 100644 packaging/python-jenkinsapi.changes create mode 100644 packaging/python-jenkinsapi.spec diff --git a/packaging/python-jenkinsapi.changes b/packaging/python-jenkinsapi.changes new file mode 100644 index 0000000..59e4137 --- /dev/null +++ b/packaging/python-jenkinsapi.changes @@ -0,0 +1,144 @@ +* Sat Jan 31 2015 Ed Bartosh 0.2.26 +- Only process non empty actions while getting job parameters +- Add support for Job Folders (CloudBees Folders Plugin). +- Fix tests. +- get_build_triggerurl logic fix +- job.get_build_triggerurl update +- making change more pythonic +- Addressing issue/221 - changing depth=1 +- Added Aleksey to primary authors list +- Version bump +- added documentation about getting version info +- move the stuff out of readme +- Added note about experimental nature of this branch +- Added Python 3.3 to this branch build spec +- Added build for Python 2.6 +- Tying to fix P3 incompatibility +- Fix wrong translation of 'except' from python2 to pytho3 +- Use print() (with 'from __future__ import print_function') +- urllib compatibility +- exception.message -> str(exception) +- basestring, unicode, str compatibility +- iteritems -> items Queue -> queue +- resolve_job_folders skipping jobs fix +- Changed Jenkins URL to download LTS version +- add unit test for multiple top level folders +- Changed Jenkins URL to download LTS version +- Added conversions from bytes to strings +- polling jenkins each time Jobs is initialized +- Add support to create Jenkins object without immediately polling jobs. +- minor fix to exception messages to improve readability. +- Adapt fingerprint to catch HTTPError from requests +- Add a few Jenkins API usage examples +- Fixed pylint violations +- Simplified get_job_url function +- Add support to create Jenkins object without immediately polling jobs. +- minor fix to exception messages to improve readability. +- Adapt fingerprint to catch HTTPError from requests +- Fixed pylint violations +- Simplified get_job_url function +- Small changes in jobs classes +- Formatting fixes +- Add test to verify fetching of plugin details, +- Fix for issue #268 and unit tests for it +- Fixed incorrect merge +- Set to use unittest2 library instead of unittest +- Added unittest2 so travis can run tests with recent Python +- Set unitest2 to be used only on python 2.6 +- Added support for 'del' in Jenkins object: remove job +- Added small delay for test_parametrized_build +- Added re-try when removing job +- Added support for 'del' in Jenkins object: remove job +- Added small delay for test_parametrized_build +- Added re-try when removing job +- Removed paragraph about Python 3 branch +- fixes job invoke when no build parameters exist for a particular job +- Fixed most of the unit tests to work on all python versions +- Fixed md5 calculation +- build.get_console() now returns string in all python versions +- Fixed assertion renamed in P3 +- Fixed most of the unit tests to work on all python versions +- Fixed md5 calculation +- build.get_console() now returns string in all python versions +- Fixed assertion renamed in P3 +- Added small delay to let jenkins catchup +- add logging url when non 200 OK response +- Added short delay to let job run for a bit +- Added section about Python versions +- Bumped Python from 3.3 to 3.4 +- Revert "Bumped Python from 3.3 to 3.4" +- Added better test to job._add_missing_builds() +- Fix for issue #280 +- Disabled "too many branches" in pylint +- Fix for P3 compatibility +- add job.get_build_metadata +- add comment about depth control +- add get_causes +- make tests more robust +- Example of adding a shell build +- Fix for issue #291 +- pre release tidy-ups and version bump +- revert accidental removel of unittest2 from the setup.py script +- add release script, fix broken landscape.io image in docs +- minor version bump +- proposed fix for #295 - crash during get_params on maven jobs +- added travis buttons to readme +- version bump +- add the __version__ feature to the package +- added a way of getting the api version from the command-line +- added tagging of releases +- fix some pep8 violations +- added additional versions of python to the travis configuration; +- tidy up travis files +- add doc upload step to the release script +- mega tidy-up of the docs +- tidy up links section +- better support for querying plugins +- pep8 tidyup and example of plugin querying +- plugin info example +- version bump +- remove parts of failing tests +- remove duplicated travis link +- ensure that tags are pushed at the end of every build +- Version bump and update deps to the latest version. Also added a link to requires.io to the readme.rst file +- Proposed fix for #297 +- interim commit - refactor of queue & invocation +- reducing the number of errors from the refactor of invocation/queues +- fix a bunch of tests +- Pep8 fixes + remove bogus imports +- Fix way more bugs. +- Trying to fix more errors. +- Fix many more bugs +- Fix some pep8 violations I had introduced. +- Cut out some more crap, but noticed that invocation of parameterized builds is broken. +- Lots of fixes +- Fix redefinition of id. +- Tidy up exceptions file. +- More fixes to parameterized builds - still broken. +- Tiny fixes. +- adding test to illustrate bug with get_revision with no scm +- Fixing get_revision with no scm +- Fixed kerberos request's interface +- Linter fixes +- adding test to illustrate bug with get_revision with no scm +- Fixing get_revision with no scm +- Fixed kerberos request's interface +- Linter fixes +- Low level api change to support tree api +- Changed job and build modules to use tree api +- Replaced _poll_if_needed with lightweight tree calls +- Added support for JENKINS_URL env. variable +- Added use of tree api to node, job, queue and fixed tests +- Pylint fixes +- added decode to test to make it work in PY 3.x +- Fix a typo in a function name in queing +- add update_config() to view +- add View.get_config() and tests covering View.get_config() as well as View.update_config() +- fix invoke(skip_if_running=True) +- Set pylint version to ensure compatibility with python 2.6 +- Set pylint version to ensure compatibility with python 2.6 +- version bump + +* Fri Jan 31 2014 Ed Bartosh 0.2.20 +- Packaging is taken from OpenSUSE + diff --git a/packaging/python-jenkinsapi.spec b/packaging/python-jenkinsapi.spec new file mode 100644 index 0000000..0382121 --- /dev/null +++ b/packaging/python-jenkinsapi.spec @@ -0,0 +1,79 @@ +# +# spec file for package python-jenkinsapi +# +# 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-jenkinsapi +Version: 0.2.26 +Release: 0 +Summary: A Python API for accessing resources on a Jenkins continuous-integration server +License: MIT +Group: Development/Languages/Python +Url: https://github.com/salimfadhley/jenkinsapi +Source: https://pypi.python.org/packages/source/j/jenkinsapi/jenkinsapi-%{version}.tar.gz + +BuildRequires: python-setuptools + +%if 0%{?suse_version} || 0%{?fedora} +BuildRequires: python-requests +Requires: python-requests +%endif + +%if 0%{?fedora} || 0%{?centos_ver} +Requires: pytz +%else +Requires: python-pytz +%endif + +%description +Jenkins is the market leading continuous integration system, originally created +by Kohsuke Kawaguchi. + +Jenkins (and It's predecessor Hudson) are useful projects for automating common +development tasks (e.g. unit-testing, production batches) - but they are +somewhat Java-centric. Thankfully the designers have provided an excellent and +complete REST interface. This library wraps up that interface as more +conventional python objects in order to make many Jenkins oriented tasks +easier to automate. + +This library can help you: + + * Query the test-results of a completed build + * Get a objects representing the latest builds of a job + * Search for artefacts by simple criteria + * Block until jobs are complete + * Install artefacts to custom-specified directory structures + * username/password auth support for jenkins instances with auth turned on + * Ability to search for builds by subversion revision + * Ability to add/remove/query Jenkins slaves + * Ability to add/remove/modify Jenkins views + +%prep +%setup -q + +%build +python setup.py build + +%install +python setup.py install --prefix=%{_prefix} --root=%{buildroot} + +%files +%defattr(-,root,root,-) +%doc README.rst +%{_bindir}/* +%{python_sitelib}/* + +%changelog + -- 2.7.4