opportunity-list 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- opportunity_list-0.1.0/PKG-INFO +22 -0
- opportunity_list-0.1.0/README.md +14 -0
- opportunity_list-0.1.0/pyproject.toml +22 -0
- opportunity_list-0.1.0/setup.cfg +4 -0
- opportunity_list-0.1.0/src/opportunity_list/main.py.py +144 -0
- opportunity_list-0.1.0/src/opportunity_list.egg-info/PKG-INFO +22 -0
- opportunity_list-0.1.0/src/opportunity_list.egg-info/SOURCES.txt +9 -0
- opportunity_list-0.1.0/src/opportunity_list.egg-info/dependency_links.txt +1 -0
- opportunity_list-0.1.0/src/opportunity_list.egg-info/entry_points.txt +2 -0
- opportunity_list-0.1.0/src/opportunity_list.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: opportunity-list
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: A Python application to manage STEM opportunities.
|
|
5
|
+
Author: Mukund
|
|
6
|
+
Requires-Python: >=3.10
|
|
7
|
+
Description-Content-Type: text/markdown
|
|
8
|
+
|
|
9
|
+
It is python terminal program in which STEM students can view add and see upcoming and ongoing projects.
|
|
10
|
+
It let us to add registration date, starting date and ending date of the event.
|
|
11
|
+
it has category of event to choose and those are-
|
|
12
|
+
Hackathon
|
|
13
|
+
Stemathon
|
|
14
|
+
Olympiad
|
|
15
|
+
Internship
|
|
16
|
+
Other.
|
|
17
|
+
you can also fill your own category in other event.
|
|
18
|
+
|
|
19
|
+
It is missing some crucial features which i will add once I have done my one sudden projects.
|
|
20
|
+
once you have added a event you can't view it anytime you want by running the code and selecting option 2
|
|
21
|
+
**note- You might not be able to edit or delete any program in this version but in upcoming version this
|
|
22
|
+
feature will be available. Please compromise for a while**
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
It is python terminal program in which STEM students can view add and see upcoming and ongoing projects.
|
|
2
|
+
It let us to add registration date, starting date and ending date of the event.
|
|
3
|
+
it has category of event to choose and those are-
|
|
4
|
+
Hackathon
|
|
5
|
+
Stemathon
|
|
6
|
+
Olympiad
|
|
7
|
+
Internship
|
|
8
|
+
Other.
|
|
9
|
+
you can also fill your own category in other event.
|
|
10
|
+
|
|
11
|
+
It is missing some crucial features which i will add once I have done my one sudden projects.
|
|
12
|
+
once you have added a event you can't view it anytime you want by running the code and selecting option 2
|
|
13
|
+
**note- You might not be able to edit or delete any program in this version but in upcoming version this
|
|
14
|
+
feature will be available. Please compromise for a while**
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=68", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "opportunity-list"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "A Python application to manage STEM opportunities."
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.10"
|
|
11
|
+
authors = [
|
|
12
|
+
{name = "Mukund"}
|
|
13
|
+
]
|
|
14
|
+
|
|
15
|
+
[project.scripts]
|
|
16
|
+
opportunity-list = "opportunity_list.main:main"
|
|
17
|
+
|
|
18
|
+
[tool.setuptools]
|
|
19
|
+
package-dir = {"" = "src"}
|
|
20
|
+
|
|
21
|
+
[tool.setuptools.packages.find]
|
|
22
|
+
where = ["src"]
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import json
|
|
2
|
+
from datetime import datetime
|
|
3
|
+
|
|
4
|
+
opportunity = []
|
|
5
|
+
|
|
6
|
+
categories = ["Hackathon", "Stemathon", "Olympiad", "Internship", "Other"]
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def parse_date(date_str):
|
|
10
|
+
try:
|
|
11
|
+
return datetime.strptime(date_str, "%Y-%m-%d")
|
|
12
|
+
except:
|
|
13
|
+
return None
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
def save_data():
|
|
17
|
+
with open("opportunities.json", "w") as file:
|
|
18
|
+
json.dump(opportunity, file, indent=4)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def load_data():
|
|
22
|
+
global opportunity
|
|
23
|
+
|
|
24
|
+
try:
|
|
25
|
+
with open("opportunities.json", "r") as file:
|
|
26
|
+
opportunity = json.load(file)
|
|
27
|
+
|
|
28
|
+
except FileNotFoundError:
|
|
29
|
+
opportunity = []
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
def add_category():
|
|
33
|
+
print("\nChoose a category of the event")
|
|
34
|
+
|
|
35
|
+
for i, cat in enumerate(categories, start=1):
|
|
36
|
+
print(f"{i}. {cat}")
|
|
37
|
+
|
|
38
|
+
choice = input("Enter number: ")
|
|
39
|
+
|
|
40
|
+
if choice.isdigit():
|
|
41
|
+
choice = int(choice)
|
|
42
|
+
|
|
43
|
+
if 1 <= choice <= len(categories):
|
|
44
|
+
selected = categories[choice - 1]
|
|
45
|
+
|
|
46
|
+
if selected == "Other":
|
|
47
|
+
custom = input("Enter custom category: ")
|
|
48
|
+
return custom
|
|
49
|
+
|
|
50
|
+
return selected
|
|
51
|
+
|
|
52
|
+
print("Invalid choice, defaulting to Other")
|
|
53
|
+
return "Other"
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
def add_opportunity():
|
|
57
|
+
name = input("Enter the name of the event: ")
|
|
58
|
+
|
|
59
|
+
if not name:
|
|
60
|
+
print("Name cannot be empty")
|
|
61
|
+
return
|
|
62
|
+
|
|
63
|
+
category = add_category()
|
|
64
|
+
|
|
65
|
+
reg_date_str = input(
|
|
66
|
+
"Enter the last date to register (YYYY-MM-DD): "
|
|
67
|
+
)
|
|
68
|
+
start_date_str = input(
|
|
69
|
+
"Enter the starting date (YYYY-MM-DD): "
|
|
70
|
+
)
|
|
71
|
+
end_date_str = input(
|
|
72
|
+
"Enter the end date (YYYY-MM-DD): "
|
|
73
|
+
)
|
|
74
|
+
|
|
75
|
+
reg_date = parse_date(reg_date_str)
|
|
76
|
+
start_date = parse_date(start_date_str)
|
|
77
|
+
end_date = parse_date(end_date_str)
|
|
78
|
+
|
|
79
|
+
if not reg_date or not start_date or not end_date:
|
|
80
|
+
print("Invalid date! Use YYYY-MM-DD format.")
|
|
81
|
+
return
|
|
82
|
+
|
|
83
|
+
if not (reg_date <= start_date <= end_date):
|
|
84
|
+
print("Date order is incorrect.")
|
|
85
|
+
return
|
|
86
|
+
|
|
87
|
+
event_details = {
|
|
88
|
+
"name": name,
|
|
89
|
+
"category": category,
|
|
90
|
+
"last date for registration": reg_date_str,
|
|
91
|
+
"starting date of the event": start_date_str,
|
|
92
|
+
"end date of the event": end_date_str,
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
opportunity.append(event_details)
|
|
96
|
+
save_data()
|
|
97
|
+
|
|
98
|
+
print("Event added successfully!")
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
def view_opportunity():
|
|
102
|
+
if not opportunity:
|
|
103
|
+
print("No events added.")
|
|
104
|
+
return
|
|
105
|
+
|
|
106
|
+
print("\n***** ALL EVENTS *****")
|
|
107
|
+
|
|
108
|
+
for i, event in enumerate(opportunity, start=1):
|
|
109
|
+
print(f"""
|
|
110
|
+
{i}. {event['name']}
|
|
111
|
+
Category: {event['category']}
|
|
112
|
+
Last Registration Date: {event['last date for registration']}
|
|
113
|
+
Starting Date: {event['starting date of the event']}
|
|
114
|
+
Ending Date: {event['end date of the event']}
|
|
115
|
+
""")
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
def main():
|
|
119
|
+
load_data()
|
|
120
|
+
|
|
121
|
+
while True:
|
|
122
|
+
print("\n***** EVENT LIST FOR STEM STUDENTS TO BOOST THEIR CAREER *****")
|
|
123
|
+
print("1. Add Event")
|
|
124
|
+
print("2. View Events")
|
|
125
|
+
print("3. Exit")
|
|
126
|
+
|
|
127
|
+
choice = input("Choose an option (1-3): ")
|
|
128
|
+
|
|
129
|
+
if choice == "1":
|
|
130
|
+
add_opportunity()
|
|
131
|
+
|
|
132
|
+
elif choice == "2":
|
|
133
|
+
view_opportunity()
|
|
134
|
+
|
|
135
|
+
elif choice == "3":
|
|
136
|
+
print("Bye!")
|
|
137
|
+
break
|
|
138
|
+
|
|
139
|
+
else:
|
|
140
|
+
print("Invalid choice.")
|
|
141
|
+
|
|
142
|
+
|
|
143
|
+
if __name__ == "__main__":
|
|
144
|
+
main()
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: opportunity-list
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: A Python application to manage STEM opportunities.
|
|
5
|
+
Author: Mukund
|
|
6
|
+
Requires-Python: >=3.10
|
|
7
|
+
Description-Content-Type: text/markdown
|
|
8
|
+
|
|
9
|
+
It is python terminal program in which STEM students can view add and see upcoming and ongoing projects.
|
|
10
|
+
It let us to add registration date, starting date and ending date of the event.
|
|
11
|
+
it has category of event to choose and those are-
|
|
12
|
+
Hackathon
|
|
13
|
+
Stemathon
|
|
14
|
+
Olympiad
|
|
15
|
+
Internship
|
|
16
|
+
Other.
|
|
17
|
+
you can also fill your own category in other event.
|
|
18
|
+
|
|
19
|
+
It is missing some crucial features which i will add once I have done my one sudden projects.
|
|
20
|
+
once you have added a event you can't view it anytime you want by running the code and selecting option 2
|
|
21
|
+
**note- You might not be able to edit or delete any program in this version but in upcoming version this
|
|
22
|
+
feature will be available. Please compromise for a while**
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
README.md
|
|
2
|
+
pyproject.toml
|
|
3
|
+
src/opportunity_list/_intit_.py
|
|
4
|
+
src/opportunity_list/main.py.py
|
|
5
|
+
src/opportunity_list.egg-info/PKG-INFO
|
|
6
|
+
src/opportunity_list.egg-info/SOURCES.txt
|
|
7
|
+
src/opportunity_list.egg-info/dependency_links.txt
|
|
8
|
+
src/opportunity_list.egg-info/entry_points.txt
|
|
9
|
+
src/opportunity_list.egg-info/top_level.txt
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
opportunity_list
|