fix resource warnings
This commit is contained in:
8
setup.py
8
setup.py
@@ -19,9 +19,13 @@ from setuptools import find_packages
|
|||||||
|
|
||||||
here = os.path.abspath(os.path.dirname(__file__))
|
here = os.path.abspath(os.path.dirname(__file__))
|
||||||
|
|
||||||
|
def read(fname):
|
||||||
|
with open(fname) as fp:
|
||||||
|
return fp.read()
|
||||||
|
|
||||||
try:
|
try:
|
||||||
README = open(os.path.join(here, 'README.txt')).read()
|
README = read(os.path.join(here, 'README.txt'))
|
||||||
CHANGES = open(os.path.join(here, 'CHANGES.txt')).read()
|
CHANGES = read(os.path.join(here, 'CHANGES.txt'))
|
||||||
except:
|
except:
|
||||||
README = ''
|
README = ''
|
||||||
CHANGES = ''
|
CHANGES = ''
|
||||||
|
Reference in New Issue
Block a user