forked from dtheodor/flask-sqlalchemy-session
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
54 lines (49 loc) · 1.93 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# -*- coding: utf-8 -*-
"""
Flask-SQLAlchemy-Session
-----------------------
Provides an SQLAlchemy scoped session that creates
unique sessions per Flask request
"""
import sys
import os
from setuptools import setup
if sys.version_info < (2, 6):
raise Exception("Flask-SQLAlchemy-Session requires Python 2.6 or higher.")
# Hard linking doesn't work inside VirtualBox shared folders. This means that
# you can't use tox in a directory that is being shared with Vagrant,
# since tox relies on `python setup.py sdist` which uses hard links. As a
# workaround, disable hard-linking if setup.py is a descendant of /vagrant.
# See
# https://stackoverflow.com/questions/7719380/python-setup-py-sdist-error-operation-not-permitted
# for more details.
if os.path.abspath(__file__).split(os.path.sep)[1] == "vagrant":
del os.link
with open("README.md", "rt", encoding="utf-8") as f:
long_description = f.read()
setup(
name="Flask-SQLAlchemy-Session2024",
version="3.0.0",
packages=["flask_sqlalchemy_session"],
author="Eduard Christian Dumitrescu",
author_email="[email protected]",
url="https://github.com/e-c-d/flask-sqlalchemy-session2024",
license="MIT",
description="SQL Alchemy session scoped on Flask requests.",
long_description=long_description,
long_description_content_type="text/markdown",
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Environment :: Web Environment",
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Software Development :: Libraries :: Python Modules",
],
# Flask should be >=0.10
install_requires=["sqlalchemy", "Flask", "Werkzeug"],
tests_require=["pytest"],
extras_require={"docs": ["Sphinx", "alabaster"]},
)