Merge pull request #90 from RonnyPfannschmidt/entrypoints

use entrypoints instead of scripts, for better use of the wheel format and modern installs
This commit is contained in:
TW 2015-07-12 15:28:40 +02:00
commit 6ed086498d
2 changed files with 7 additions and 9 deletions

View File

@ -1,4 +0,0 @@
#!/usr/bin/env python
from borg.archiver import main
main()

View File

@ -16,10 +16,8 @@ if sys.version_info < min_python:
print("Borg requires Python %d.%d or later" % min_python)
sys.exit(1)
try:
from setuptools import setup, Extension
except ImportError:
from distutils.core import setup, Extension
from setuptools import setup, Extension
crypto_source = 'borg/crypto.pyx'
chunker_source = 'borg/chunker.pyx'
@ -129,7 +127,11 @@ setup(
'Topic :: System :: Archiving :: Backup',
],
packages=['borg', 'borg.testsuite'],
scripts=['scripts/borg'],
entry_points={
'console_scripts': [
'borg = borg.archiver:main',
]
},
cmdclass=cmdclass,
ext_modules=ext_modules,
# msgpack pure python data corruption was fixed in 0.4.6.