Skip to content

Commit

Permalink
🤝 take latest code from setupmobans and release 0.5.1 🥚 🎡, which carr…
Browse files Browse the repository at this point in the history
…ies LICENSE file, pyexcel/pyexcel#103
  • Loading branch information
chfw committed Oct 20, 2017
1 parent 1f063e0 commit 3168dae
Show file tree
Hide file tree
Showing 7 changed files with 68 additions and 19 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
Change log
================================================================================

0.5.1 - 20.10.2017
--------------------------------------------------------------------------------

added
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

#. `#103 <https://github.com/pyexcel/pyexcel/issues/103>`_, include LICENSE file
in MANIFEST.in, meaning LICENSE file will appear in the released tar ball.

0.5.0 - 30.08.2017
--------------------------------------------------------------------------------

Expand Down
4 changes: 2 additions & 2 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@

project = u'pyexcel-odsr'
copyright = u'2015-2017 Onni Software Ltd.'
version = '0.5.0'
release = '0.5.0'
version = '0.5.1'
release = '0.5.1'
exclude_patterns = []
pygments_style = 'sphinx'
html_theme = 'default'
Expand Down
6 changes: 3 additions & 3 deletions pyexcel_odsr.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
overrides: "pyexcel.yaml"
name: "pyexcel-odsr"
nick_name: odsr
version: 0.5.0
current_version: 0.5.0
release: 0.5.0
version: 0.5.1
current_version: 0.5.1
release: 0.5.1
file_type: ods
dependencies:
- pyexcel-io>=0.5.0
Expand Down
2 changes: 1 addition & 1 deletion pyexcel_odsr/_version.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Auto generated by moban
__version__ = '0.5.0'
__version__ = '0.5.1'
__author__ = 'C.W.'
62 changes: 51 additions & 11 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
try:
from setuptools import setup, find_packages
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup, find_packages
# Template by setupmobans
import os
import sys
import codecs
from shutil import rmtree
from setuptools import setup, find_packages, Command

NAME = 'pyexcel-odsr'
AUTHOR = 'C.W.'
VERSION = '0.5.0'
VERSION = '0.5.1'
EMAIL = '[email protected]'
LICENSE = 'New BSD'
DESCRIPTION = (
Expand All @@ -16,8 +16,8 @@
''
)
URL = 'https://github.com/pyexcel/pyexcel-odsr'
DOWNLOAD_URL = '%s/archive/0.5.0.tar.gz' % URL
FILES = ['README.rst', 'CONTRIBUTORS.rst', 'CHANGELOG.rst']
DOWNLOAD_URL = '%s/archive/0.5.1.tar.gz' % URL
FILES = ['README.rst', 'CONTRIBUTORS.rst', 'CHANGELOG.rst']
KEYWORDS = [
'excel',
'ods',
Expand Down Expand Up @@ -48,6 +48,42 @@
PACKAGES = find_packages(exclude=['ez_setup', 'examples', 'tests'])
EXTRAS_REQUIRE = {
}
PUBLISH_COMMAND = '{0} setup.py sdist bdist_wheel upload -r pypi'.format(
sys.executable)
GS_COMMAND = ('gs pyexcel-odsr v0.5.1 ' +
"Find 0.5.1 in changelog for more details")
here = os.path.abspath(os.path.dirname(__file__))


class PublishCommand(Command):
"""Support setup.py upload."""

description = 'Build and publish the package on github and pypi'
user_options = []

@staticmethod
def status(s):
"""Prints things in bold."""
print('\033[1m{0}\033[0m'.format(s))

def initialize_options(self):
pass

def finalize_options(self):
pass

def run(self):
try:
self.status('Removing previous builds...')
rmtree(os.path.join(here, 'dist'))
except OSError:
pass

self.status('Building Source and Wheel (universal) distribution...')
if os.system(GS_COMMAND) == 0:
os.system(PUBLISH_COMMAND)

sys.exit()


def read_files(*files):
Expand All @@ -61,7 +97,7 @@ def read_files(*files):

def read(afile):
"""Read a file into setup"""
with open(afile, 'r') as opened_file:
with codecs.open(afile, 'r', 'utf-8') as opened_file:
content = filter_out_test_code(opened_file)
content = "".join(list(content))
return content
Expand Down Expand Up @@ -109,5 +145,9 @@ def filter_out_test_code(file_handle):
packages=PACKAGES,
include_package_data=True,
zip_safe=False,
classifiers=CLASSIFIERS
classifiers=CLASSIFIERS,
setup_requires=['gease'],
cmdclass={
'publish': PublishCommand,
}
)
2 changes: 1 addition & 1 deletion test.bat
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
pip freeze
nosetests --with-cov --cover-package pyexcel_odsr --cover-package tests --with-doctest --doctest-extension=.rst README.rst tests docs/source pyexcel_odsr && flake8 . --exclude=.moban.d --builtins=unicode,xrange,long
nosetests --with-coverage --cover-package pyexcel_odsr --cover-package tests --with-doctest --doctest-extension=.rst README.rst tests docs/source pyexcel_odsr && flake8 . --exclude=.moban.d --builtins=unicode,xrange,long
2 changes: 1 addition & 1 deletion test.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
pip freeze
nosetests --with-cov --cover-package pyexcel_odsr --cover-package tests --with-doctest --doctest-extension=.rst README.rst tests docs/source pyexcel_odsr && flake8 . --exclude=.moban.d --builtins=unicode,xrange,long
nosetests --with-coverage --cover-package pyexcel_odsr --cover-package tests --with-doctest --doctest-extension=.rst README.rst tests docs/source pyexcel_odsr && flake8 . --exclude=.moban.d --builtins=unicode,xrange,long

0 comments on commit 3168dae

Please sign in to comment.