Inder-26 commited on
Commit
f5e608c
·
1 Parent(s): 4984a47

setup.py ready

Browse files
Files changed (2) hide show
  1. requirement.txt → requirements.txt +7 -1
  2. setup.py +29 -0
requirement.txt → requirements.txt RENAMED
@@ -1,3 +1,9 @@
1
  python-dotenv
2
  numpy
3
- pandas
 
 
 
 
 
 
 
1
  python-dotenv
2
  numpy
3
+ pandas
4
+ setuptools
5
+ pymongo
6
+ certifi
7
+
8
+
9
+ #-e .
setup.py CHANGED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ '''
2
+ The setup.py file is a build script for setuptools, used to package and distribute Python projects.
3
+ It typically contains metadata about the project, such as its name, version, author, and dependencies, as well as instructions on how to install the package.
4
+ '''
5
+ from setuptools import setup, find_packages
6
+ from typing import List
7
+
8
+ def get_requirements()-> List[str]:
9
+ requirement_lst=[]
10
+ """Reads the requirements.txt file and returns a list of dependencies."""
11
+ try:
12
+ with open('requirements.txt','r') as file:
13
+ lines=file.readlines()
14
+ for line in lines:
15
+ requirement=line.strip()
16
+ if requirement and requirement != '-e .':
17
+ requirement_lst.append(requirement)
18
+ except FileNotFoundError:
19
+ print("requirement.txt file not found")
20
+
21
+ return requirement_lst
22
+
23
+ setup(
24
+ name="Network Security",
25
+ version="0.0.1",
26
+ author="Inderjeet Singh",
27
+ packages=find_packages(),
28
+ install_requires=get_requirements()
29
+ )