forked from getomni-ai/zerox
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.py
More file actions
28 lines (24 loc) · 768 Bytes
/
setup.py
File metadata and controls
28 lines (24 loc) · 768 Bytes
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
from setuptools import setup, find_packages
from setuptools.command.install import install
import subprocess
import sys
class InstallSystemDependencies(install):
def run(self):
try:
subprocess.check_call(
[sys.executable, "-m", "py_hadid.scripts.pre_install"]
)
except subprocess.CalledProcessError as e:
print(f"Pre-install script failed: {e}", file=sys.stderr)
sys.exit(1)
install.run(self)
setup(
name="py-hadid",
cmdclass={
"install": InstallSystemDependencies,
},
version="0.0.7",
packages=find_packages(where="py_hadid"), # Specify the root folder
package_dir={"": "py_hadid"}, # Map root directory
include_package_data=True,
)