All Projects → rfyiamcool → format_converter

rfyiamcool / format_converter

Licence: MIT License
转换数据格式

Programming Languages

python
139335 projects - #7 most used programming language

format_converter

该项目的用途相当的简单,是用来转换数据格式的. 比如把json转换成yaml,json转换成csv. 现在支持的格式有json、txt、csv、yaml.

安装:

pip install format_converter
git clone https://github.com/rfyiamcool/format_converter.git
cd format_converter
python setup.py install

使用说明:

from format_converter import converter

data = converter < 'data.json'

读取配置

data = converter < 'file.json'
data = converter < 'file.txt'
data = converter.json < 'file.json'
data = converter.yml < 'file.yml'
data = converter.csv < 'file.csv'

写入配置

converter(data) > 'file.json'
converter(data) > 'file.txt'
converter.json(data) > 'file.json'
converter.yml(data) > 'file.yml'

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].