alignment with commons
This commit is contained in:
parent
419b3e3a10
commit
669bc64261
|
@ -125,6 +125,12 @@ Continue from previous example:
|
||||||
As a pyexcel plugin
|
As a pyexcel plugin
|
||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
No longer, explicit import is needed since pyexcel version 0.2.2. Instead,
|
||||||
|
this library is auto-loaded. So if you want to read data in xls format,
|
||||||
|
installing it is enough.
|
||||||
|
|
||||||
|
Any version under pyexcel 0.2.2, you have to keep doing the following:
|
||||||
|
|
||||||
Import it in your file to enable this plugin:
|
Import it in your file to enable this plugin:
|
||||||
|
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
|
@ -141,7 +147,7 @@ Here is the sample code:
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
|
|
||||||
>>> import pyexcel as pe
|
>>> import pyexcel as pe
|
||||||
>>> from pyexcel.ext import xls
|
>>> # from pyexcel.ext import xls
|
||||||
>>> sheet = pe.get_book(file_name="your_file.xls")
|
>>> sheet = pe.get_book(file_name="your_file.xls")
|
||||||
>>> sheet
|
>>> sheet
|
||||||
Sheet Name: Sheet 1
|
Sheet Name: Sheet 1
|
||||||
|
|
99
setup.py
99
setup.py
|
@ -5,51 +5,37 @@ except ImportError:
|
||||||
use_setuptools()
|
use_setuptools()
|
||||||
from setuptools import setup, find_packages
|
from setuptools import setup, find_packages
|
||||||
|
|
||||||
with open("README.rst", 'r') as readme:
|
NAME = 'pyexcel-xls'
|
||||||
README_txt = readme.read()
|
AUTHOR = 'C.W.'
|
||||||
|
VERSION = '0.2.0'
|
||||||
|
EMAIL = 'wangc_2011 (at) hotmail.com'
|
||||||
|
LICENSE = 'New BSD'
|
||||||
|
PACKAGES = find_packages(exclude=['ez_setup', 'examples', 'tests'])
|
||||||
|
DESCRIPTION = 'A wrapper library to read, manipulate and write data in xls format. It reads xlsx and xlsm format'
|
||||||
|
KEYWORDS = [
|
||||||
|
'excel',
|
||||||
|
'python',
|
||||||
|
'pyexcel',
|
||||||
|
'xls',
|
||||||
|
'xlsx',
|
||||||
|
'xlsm'
|
||||||
|
]
|
||||||
|
|
||||||
with open("CHANGELOG.rst", 'r') as changelog:
|
INSTALL_REQUIRES = [
|
||||||
README_txt += changelog.read()
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
'pyexcel-io>=0.1.0',
|
'pyexcel-io>=0.1.0',
|
||||||
'xlrd',
|
'xlrd',
|
||||||
'xlwt-future',
|
'xlwt-future',
|
||||||
]
|
]
|
||||||
|
|
||||||
extras = {}
|
EXTRAS_REQUIRE = {}
|
||||||
|
|
||||||
|
CLASSIFIERS = [
|
||||||
setup(
|
'Topic :: Office/Business',
|
||||||
name='pyexcel-xls',
|
'Topic :: Utilities',
|
||||||
author='C.W.',
|
'Topic :: Software Development :: Libraries',
|
||||||
version='0.2.0',
|
'Programming Language :: Python',
|
||||||
author_email='wangc_2011 (at) hotmail.com',
|
'License :: OSI Approved :: BSD License',
|
||||||
url='https://github.com/pyexcel/pyexcel-xls',
|
'Intended Audience :: Developers',
|
||||||
description='A wrapper library to read, manipulate and write data in xls format. It reads xlsx and xlsm format',
|
|
||||||
install_requires=dependencies,
|
|
||||||
extras_require=extras,
|
|
||||||
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
|
|
||||||
include_package_data=True,
|
|
||||||
long_description=README_txt,
|
|
||||||
zip_safe=False,
|
|
||||||
tests_require=['nose'],
|
|
||||||
keywords=[
|
|
||||||
'excel',
|
|
||||||
'python',
|
|
||||||
'pyexcel',
|
|
||||||
'xls',
|
|
||||||
'xlsx',
|
|
||||||
'xlsm'
|
|
||||||
],
|
|
||||||
license='New BSD',
|
|
||||||
classifiers=[
|
|
||||||
'Topic :: Office/Business',
|
|
||||||
'Topic :: Utilities',
|
|
||||||
'Topic :: Software Development :: Libraries',
|
|
||||||
'Programming Language :: Python',
|
|
||||||
'License :: OSI Approved :: BSD License',
|
|
||||||
'Intended Audience :: Developers',
|
|
||||||
'Development Status :: 3 - Alpha',
|
'Development Status :: 3 - Alpha',
|
||||||
'Programming Language :: Python :: 2.6',
|
'Programming Language :: Python :: 2.6',
|
||||||
'Programming Language :: Python :: 2.7',
|
'Programming Language :: Python :: 2.7',
|
||||||
|
@ -57,5 +43,38 @@ setup(
|
||||||
'Programming Language :: Python :: 3.4',
|
'Programming Language :: Python :: 3.4',
|
||||||
'Programming Language :: Python :: 3.5',
|
'Programming Language :: Python :: 3.5',
|
||||||
'Programming Language :: Python :: Implementation :: PyPy'
|
'Programming Language :: Python :: Implementation :: PyPy'
|
||||||
]
|
]
|
||||||
)
|
|
||||||
|
|
||||||
|
def read_files(*files):
|
||||||
|
"""Read files into setup"""
|
||||||
|
text = ""
|
||||||
|
for single_file in files:
|
||||||
|
text = text + read(single_file) + "\n"
|
||||||
|
return text
|
||||||
|
|
||||||
|
|
||||||
|
def read(afile):
|
||||||
|
"""Read a file into setup"""
|
||||||
|
with open(afile, 'r') as opened_file:
|
||||||
|
return opened_file.read()
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
setup(
|
||||||
|
name=NAME,
|
||||||
|
author=AUTHOR,
|
||||||
|
version=VERSION,
|
||||||
|
author_email=EMAIL,
|
||||||
|
description=DESCRIPTION,
|
||||||
|
install_requires=INSTALL_REQUIRES,
|
||||||
|
keywords=KEYWORDS,
|
||||||
|
extras_require=EXTRAS_REQUIRE,
|
||||||
|
packages=PACKAGES,
|
||||||
|
include_package_data=True,
|
||||||
|
long_description=read_files('README.rst', 'CHANGELOG.rst'),
|
||||||
|
zip_safe=False,
|
||||||
|
tests_require=['nose'],
|
||||||
|
license=LICENSE,
|
||||||
|
classifiers=CLASSIFIERS
|
||||||
|
)
|
Loading…
Reference in New Issue