| @@ -4,3 +4,4 @@ dist | |||
| *.egg | |||
| .tox | |||
| ~*.* | |||
| build/ | |||
| @@ -1,11 +1,59 @@ | |||
| language: python | |||
| sudo: false | |||
| env: | |||
| - TOX_ENV=py26 | |||
| - TOX_ENV=py27 | |||
| - TOX_ENV=py33 | |||
| - TOX_ENV=py34 | |||
| os: | |||
| - linux | |||
| python: | |||
| - '2.7' | |||
| - '3.3' | |||
| - '3.4' | |||
| install: | |||
| - pip install tox | |||
| - pip -q install coveralls six autopep8 | |||
| script: | |||
| - tox -e $TOX_ENV | |||
| - curl --silent -Lo travis_after_all.py https://raw.github.com/pycontribs/travis_after_all/master/travis_after_all.py && travis_wait python setup.py prerelease test | |||
| - export PACKAGE_VERSION=$(python -c "from wstools.version import __version__; print(__version__)") | |||
| after_success: | |||
| - python travis_after_all.py | |||
| - export $(cat .to_export_back) | |||
| - | | |||
| if [ "$BUILD_LEADER" = "YES" ]; then | |||
| if [ "$BUILD_AGGREGATE_STATUS" = "others_succeeded" ]; then | |||
| echo "All jobs succeeded! PUBLISHING..." | |||
| else | |||
| echo "Some jobs failed" | |||
| fi | |||
| fi | |||
| - coveralls | |||
| - python setup.py sdist bdist_wheel | |||
| after_failure: | |||
| - python travis_after_all.py | |||
| - export $(cat .to_export_back) | |||
| - | | |||
| if [ "$BUILD_LEADER" = "YES" ]; then | |||
| if [ "$BUILD_AGGREGATE_STATUS" = "others_failed" ]; then | |||
| echo "All jobs failed" | |||
| else | |||
| echo "Some jobs failed" | |||
| fi | |||
| fi | |||
| after_script: | |||
| - echo leader=$BUILD_LEADER status=$BUILD_AGGREGATE_STATUS | |||
| branches: | |||
| only: | |||
| - master | |||
| before_deploy: | |||
| - echo "before deploy..." | |||
| deploy: | |||
| - provider: releases | |||
| api_key: | |||
| - secure: "gr9iOcQjdoAyUAim6FWKzJI9MBaJo9XKfGQGu7wdPXUFhg80Rp6GLJsowP+aU94NjXM1UQlVHDAy627WtjBlLH2SvmVEIIr7+UKBopBYuXG5jJ1m3wOZE+4f1Pqe9bqFc1DxgucqE8qF0sC24fIbNM2ToeyYrxrS6RoL2gRrX2I=" | |||
| file: "dist/jira-$PACKAGE_VERSION.tar.gz" | |||
| skip_cleanup: true | |||
| on: | |||
| condition: "$BUILD_LEADER = YES" | |||
| - provider: pypi | |||
| user: sorin | |||
| password: | |||
| secure: "E0cjANF7SLBdYrsnWLK8X/xWznqkF0JrP/DVfDazPzUYH6ynFeneyofzNJQPLTLsqe1eKXhuUJ/Sbl+RHFB0ySo/j/7NfYd/9pm8hpUkGCvR09IwtvMLgWKp3k10NWab03o2GOkSJSrLvZofyZBGR40wwu2O9uXPCb2rvucCGbw=" | |||
| distributions: "sdist bdist_wheel" | |||
| on: | |||
| condition: "$BUILD_LEADER = YES" | |||
| @@ -1,20 +1,9 @@ | |||
| #!/bin/bash | |||
| set -ex | |||
| VERSION=$(python -c "from src.wstools.version import __version__ ; print __version__") | |||
| VERSION=$(python -c "from wstools.version import __version__ ; print __version__") | |||
| echo Preparing to release version $VERSION | |||
| #source tox | |||
| #pip install --upgrade pep8 autopep8 docutils | |||
| echo === Testings === | |||
| if ! python setup.py test; then | |||
| echo "The test suite failed. Fix it!" | |||
| exit 1 | |||
| fi | |||
| echo === Chechink that all changes are commited and pushed === | |||
| git pull -u | |||
| @@ -34,23 +23,31 @@ git diff | |||
| exit 1 | |||
| fi | |||
| git log --date=short --pretty=format:"%cd %s" > CHANGELOG | |||
| git diff | |||
| echo "Please don't run this as a user. This generates a new release for PyPI. Press ^C to exit or Enter to continue." | |||
| read | |||
| if [ -v PS1 ] ; then | |||
| echo "Automatic deployment" | |||
| else | |||
| echo "Please don't run this as a user. This generates a new release for PyPI. Press ^C to exit or Enter to continue." | |||
| read | |||
| fi | |||
| git add CHANGELOG | |||
| git commit -a "Auto-generating release notes." | |||
| # Clear old distutils stuff | |||
| rm -rf build dist MANIFEST &> /dev/null | |||
| git tag -f -a $VERSION -m "Version $VERSION" | |||
| git tag -f -a RELEASE -m "Current RELEASE" | |||
| # Build installers, etc. and upload to PyPI | |||
| # python setup.py register sdist bdist_wininst upload | |||
| NEW_VERSION="${VERSION%.*}.$((${VERSION##*.}+1))" | |||
| set -ex | |||
| sed -i ~ "s/${VERSION}/${NEW_VERSION}/" wstools/version.py | |||
| #python setup.py register sdist build_sphinx upload upload_sphinx | |||
| python setup.py register sdist upload | |||
| git commit -a "Auto-increasing the version number after a release." | |||
| git tag -f -a $VERSION -m "Version $VERSION" | |||
| git tag -f -a RELEASE -m "Current RELEASE" | |||
| # disables because this is done only by Travis CI from now, which calls this script after that. | |||
| #python setup.py register sdist bdist_wheel build_sphinx upload_docs upload --sign | |||
| git push origin --tags | |||
| git push --force origin --tags | |||
| echo "done." | |||
| @@ -16,6 +16,7 @@ upload-dir = docs/build/html | |||
| norecursedirs = . .svn jira _build tmp* lib/third lib *.egg bin distutils build docs demo | |||
| python_files = *.py | |||
| addopts = -p no:xdist --ignore=setup.py --tb=long -rsxX -v --maxfail=10 --pep8 tests | |||
| timeout=60 | |||
| # --maxfail=2 -n4 | |||
| # -n4 runs up to 4 parallel procs | |||
| # --maxfail=2 fail fast, dude | |||
| @@ -129,6 +129,7 @@ class PreRelease(Command): | |||
| raise RuntimeError( | |||
| "Current version of the package is equal or lower than the already published ones (PyPi). Increse version to be able to pass prerelease stage.") | |||
| requires = ['autopep8', 'six', 'pep8', 'pytest-cov', 'pytest-pep8', 'setuptools', 'pytest', 'pytest-timeout'] | |||
| setup( | |||
| name=NAME, | |||
| @@ -136,7 +137,9 @@ setup( | |||
| cmdclass={'test': PyTest, 'release': Release, 'prerelease': PreRelease}, | |||
| packages=find_packages(exclude=['tests']), | |||
| include_package_data=True, | |||
| install_requires=['docutils','six'], | |||
| tests_require=requires, | |||
| setup_requires=requires, | |||
| install_requires=requires, | |||
| license='BSD', | |||
| description="WSDL parsing services package for Web Services for Python. see" + url, | |||
| @@ -152,18 +155,14 @@ setup( | |||
| keywords='api wstools wdsl web', | |||
| classifiers=[ | |||
| 'Programming Language :: Python', | |||
| 'Programming Language :: Python :: 2.5', | |||
| 'Programming Language :: Python :: 2.6', | |||
| 'Programming Language :: Python :: 2.7', | |||
| 'Programming Language :: Python :: 3', | |||
| 'Development Status :: 4 - Beta', | |||
| 'Development Status :: 5 - Production/Stable', | |||
| 'Environment :: Other Environment', | |||
| 'Intended Audience :: Developers', | |||
| 'License :: OSI Approved :: BSD License', | |||
| 'Operating System :: OS Independent', | |||
| 'Topic :: Software Development :: Libraries :: Python Modules', | |||
| 'Programming Language :: Python :: 2.6', | |||
| 'Programming Language :: Python :: 2.7', | |||
| 'Programming Language :: Python :: 3.3', | |||
| 'Programming Language :: Python :: 3.4', | |||
| 'Topic :: Internet :: WWW/HTTP', | |||
| @@ -1,6 +1,6 @@ | |||
| [tox] | |||
| minversion = 1.3 | |||
| envlist = py26,py27,py34,flake8 | |||
| envlist = py27,py34,flake8 | |||
| [testenv] | |||
| deps= | |||
| @@ -12,8 +12,6 @@ commands= | |||
| bash -c "coveralls || true" | |||
| whitelist_externals=bash | |||
| [testenv:py26] | |||
| [testenv:py27] | |||
| [testenv:py33] | |||