|
1 | | -import os |
2 | | - |
3 | | -from setuptools import find_packages, setup |
4 | | - |
5 | | -VERSION = __import__("herald").__version__ |
6 | | - |
7 | | - |
8 | | -def read_file(filename): |
9 | | - """Read a file into a string""" |
10 | | - path = os.path.abspath(os.path.dirname(__file__)) |
11 | | - filepath = os.path.join(path, filename) |
12 | | - try: |
13 | | - return open(filepath).read() |
14 | | - except IOError: |
15 | | - return "" |
16 | | - |
17 | | - |
18 | | -install_requires = [ |
19 | | - "django>=3.2", |
20 | | - "jsonpickle", |
21 | | -] |
22 | | -dev_requires = [ |
23 | | - "pytz", |
24 | | -] |
25 | | -twilio_requires = [ |
26 | | - "twilio", |
27 | | -] |
28 | | -html2text_requires = [ |
29 | | - "html2text", |
30 | | -] |
31 | | - |
32 | | -setup( |
33 | | - name="django-heralder", |
34 | | - version=VERSION, |
35 | | - author="PJ Farrell", |
36 | | - author_email="pjf@maepub.com", |
37 | | - install_requires=install_requires, |
38 | | - extras_require={ |
39 | | - "dev": install_requires + dev_requires, |
40 | | - "twilio": twilio_requires, |
41 | | - "html2text": html2text_requires, |
42 | | - }, |
43 | | - packages=find_packages(exclude=["tests"]), |
44 | | - include_package_data=True, # declarations in MANIFEST.in |
45 | | - license="MIT", |
46 | | - url="https://github.com/peterfarrell/django-heralder/", |
47 | | - download_url="https://github.com/peterfarrell/django-heralder/tarball/" + VERSION, |
48 | | - description="Django library for separating the message content from transmission method", |
49 | | - long_description=read_file("README.md"), |
50 | | - long_description_content_type="text/markdown", |
51 | | - keywords=["django", "notifications", "messaging"], |
52 | | - classifiers=[ |
53 | | - "Framework :: Django", |
54 | | - "Intended Audience :: Developers", |
55 | | - "Framework :: Django", |
56 | | - "Framework :: Django :: 3.2", |
57 | | - "Framework :: Django :: 4.2", |
58 | | - "Framework :: Django :: 5.2", |
59 | | - "Programming Language :: Python", |
60 | | - "Programming Language :: Python :: 3", |
61 | | - "Programming Language :: Python :: 3.7", |
62 | | - "Programming Language :: Python :: 3.8", |
63 | | - "Programming Language :: Python :: 3.9", |
64 | | - "Programming Language :: Python :: 3.10", |
65 | | - "Programming Language :: Python :: 3.11", |
66 | | - "Programming Language :: Python :: 3.12", |
67 | | - "Programming Language :: Python :: 3 :: Only", |
68 | | - "License :: OSI Approved :: MIT License", |
69 | | - ], |
| 1 | +import sys |
| 2 | + |
| 3 | +sys.stderr.write( |
| 4 | + """\ |
| 5 | +=============================== |
| 6 | +Unsupported installation method |
| 7 | +=============================== |
| 8 | +This project no longer supports installation with `python setup.py install .`. |
| 9 | +Please use `python -m pip install .` instead. |
| 10 | +""" |
70 | 11 | ) |
| 12 | +sys.exit(1) |
0 commit comments