Repository navigation
Expand file tree
/
Copy pathsetup.py
More file actions
69 lines (60 loc) · 1.83 KB
/
Copy pathsetup.py
File metadata and controls
69 lines (60 loc) · 1.83 KB
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
from setuptools import setup, find_packages
from setuptools.command.install import install
from pathlib import Path
import subprocess
import mailhound
import yaml
class PostInstallCommand(install):
def run(self):
subprocess.check_call(['playwright', 'install'])
install.run(self)
providers_file = Path('~/.config/mailhound/providers.yaml').expanduser()
providers_file.parent.mkdir(parents=True, exist_ok=True)
new_providers = {
'snov_up': None,
'minelead_key': None,
'hunter_key': None,
}
# If the providers.yaml file exists, load its content and update the new_providers dictionary
if providers_file.is_file():
with providers_file.open('r') as f:
providers = yaml.safe_load(f)
for key in new_providers.keys():
if key in providers:
new_providers[key] = providers[key]
with providers_file.open('w') as f:
yaml.dump(new_providers, f)
with open('README.md', 'r') as f:
long_description = f.read()
setup(
name='mailhound',
version=mailhound.__version__,
author='null3yte',
description='A simple tool to find emails of a domain',
include_package_data=True,
license='MIT',
packages=find_packages(),
long_description=long_description,
long_description_content_type='text/markdown',
url="https://github.com/null3yte/mailhound",
python_requires='>=3.6',
entry_points={
'console_scripts': [
'mailhound=mailhound.__main__:main',
],
},
install_requires=[
"aiohttp~=3.8.4",
"PyYAML~=6.0.1",
"playwright~=1.36.0",
"setuptools~=65.5.0",
],
classifiers=[
'Programming Language :: Python :: 3',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
],
cmdclass={
'install': PostInstallCommand,
}
)