🔨 code refactoring on v0.6.0
This commit is contained in:
parent
fc0e6088f3
commit
43a5a56227
|
@ -31,7 +31,7 @@ author = u'C.W.'
|
|||
# The short X.Y version
|
||||
version = u'0.5.9.1'
|
||||
# The full version, including alpha/beta/rc tags
|
||||
release = u'0.5.9.1'
|
||||
release = u'0.6.0'
|
||||
|
||||
|
||||
# -- General configuration ---------------------------------------------------
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
:Source code: http://github.com/pyexcel/pyexcel-io.git
|
||||
:Issues: http://github.com/pyexcel/pyexcel-io/issues
|
||||
:License: New BSD License
|
||||
:Development: |release|
|
||||
:Released: |version|
|
||||
:Generated: |today|
|
||||
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
overrides: "pyexcel.yaml"
|
||||
name: "pyexcel-io"
|
||||
nick_name: io
|
||||
version: 0.5.9.1
|
||||
current_version: 0.5.9.1
|
||||
version: 0.6.0
|
||||
current_version: 0.6.0
|
||||
release: 0.5.9.1
|
||||
dependencies:
|
||||
- ordereddict;python_version<"2.7"
|
||||
|
|
|
@ -119,29 +119,13 @@ def save_data(afile, data, file_type=None, **keywords):
|
|||
if no_file_type:
|
||||
file_type = constants.FILE_FORMAT_CSV
|
||||
|
||||
store_data(
|
||||
afile,
|
||||
to_store,
|
||||
file_type=file_type,
|
||||
single_sheet_in_book=single_sheet_in_book,
|
||||
**keywords
|
||||
)
|
||||
|
||||
|
||||
def store_data(afile, data, file_type=None, **keywords):
|
||||
"""Non public function to store data to afile
|
||||
|
||||
:param filename: actual file name, a file stream or actual content
|
||||
:param data: the data to be written
|
||||
:param file_type: used only when filename is not a physial file name
|
||||
:param keywords: any other parameters
|
||||
"""
|
||||
if isstream(afile):
|
||||
keywords.update(dict(file_stream=afile, file_type=file_type))
|
||||
else:
|
||||
keywords.update(dict(file_name=afile, file_type=file_type))
|
||||
keywords['single_sheet_in_book'] = single_sheet_in_book
|
||||
with get_writer(**keywords) as writer:
|
||||
writer.write(data)
|
||||
writer.write(to_store)
|
||||
|
||||
|
||||
def load_data(
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
.
|
||||
https://github.com/chfw/lml/archive/master.zip
|
||||
https://github.com/pyexcel/pyexcel/archive/master.zip
|
||||
https://github.com/pyexcel/pyexcel-xls/archive/master.zip
|
||||
https://github.com/pyexcel/pyexcel-xls/archive/dev.zip
|
||||
|
||||
|
|
Loading…
Reference in New Issue