Skip to content

Commit

Permalink
refactor setup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
sanori committed Oct 4, 2016
2 parents 7cb65bd + 8f09dd4 commit 70624c1
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 7 deletions.
23 changes: 16 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,31 @@
from distutils.core import setup
from setuptools import setup
import pypandoc

long_description = pypandoc.convert('README.md', 'rst')

def find_version(filename):
with open(filename) as f:
for line in f:
if line.startswith('__version__'):
return eval(line.split('=')[-1])

setup(
name='unzipmbcs',
py_modules=['unzipmbcs'],
version='0.1.1',
version=find_version('unzipmbcs.py'),
description='UnZip for non-UTF8 encoding such as cp949, sjis, gbk, euc-kr, euc-jp, and gb2312',
long_description=long_description,
keywords='unzip, pkzip, non-UTF8, mbcs, cp949, sjis, shift_jis, gbk, gb18030',
author='Joo-Won Jung',
author_email='sanori@gmail.com',
url='https://github.com/sanori/unzip-mbcs',
download_url='https://github.com/sanori/unzip-mbcs/tarball/0.1.1',
keywords=['unzip', 'pkzip', 'non-UTF8', 'mbcs', 'cp949',
'sjis', 'shift_jis', 'gbk', 'gb18030'],
py_modules=['unzipmbcs'],
classifiers=['Development Status :: 3 - Alpha',
'License :: OSI Approved :: Apache Software License',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 3'],
entry_points={
'console_scripts': [
'unzipmbcs=unzipmbcs:_main',
'unzipmbcs = unzipmbcs:_main',
],
},
)
1 change: 1 addition & 0 deletions unzipmbcs.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import zlib
import argparse

__version__ = '0.1.1'

def fixZipFilename(filename, enc):
"""
Expand Down

0 comments on commit 70624c1

Please # to comment.