Skip to content

Commit 8b49855

Browse files
committed
setup.py: Use entry_points instead of providing scripts ourselves
1 parent fcf5573 commit 8b49855

File tree

3 files changed

+7
-12
lines changed

3 files changed

+7
-12
lines changed

scripts/wpull

-3
This file was deleted.

scripts/wpull3

-3
This file was deleted.

setup.py

+7-6
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
#!/usr/bin/env python
22

3-
try:
4-
from setuptools import setup
5-
except ImportError:
6-
from distutils.core import setup
3+
from setuptools import setup
74

85
from distutils.version import StrictVersion
96
import os.path
@@ -90,6 +87,12 @@ def get_version():
9087
],
9188
packages=PROJECT_PACKAGES,
9289
package_dir=PROJECT_PACKAGE_DIR,
90+
entry_points={
91+
'console_scripts': [
92+
'wpull=wpull.application.main:main',
93+
'wpull3=wpull.application.main:main',
94+
],
95+
},
9396
)
9497

9598

@@ -108,8 +111,6 @@ def get_version():
108111
if sys.version_info < (3, 5):
109112
setup_kwargs['install_requires'].append('typing')
110113

111-
setup_kwargs['scripts'] = ['scripts/wpull', 'scripts/wpull3']
112-
113114

114115
if __name__ == '__main__':
115116
if sys.version_info[0] < 3:

0 commit comments

Comments
 (0)