Skip to content

Commit fd67603

Browse files
Resume Builder: include interships section in generated PDF
1 parent d43108c commit fd67603

File tree

1 file changed

+15
-13
lines changed

1 file changed

+15
-13
lines changed

Resume Builder/resume_builder.py

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,21 @@ def generate_pdf():
214214
pdf.cell(0, 10, proj["name"], 0, 1)
215215
pdf.multi_cell(0, 10, proj["description"])
216216
pdf.cell(0, 10, f"Technologies Used: {proj['technologies']}", 0, 1)
217+
# Internships
218+
if resume_data["internships"]:
219+
pdf.set_font('Arial', 'B', 12)
220+
pdf.cell(0, 10, "Internships", 0, 1)
221+
pdf.set_font('Arial', '', 11)
222+
for it in resume_data["internships"]:
223+
hdr = f"{it['role']} at {it['company']}"
224+
if it.get("location"):
225+
hdr += f" — {it['location']}"
226+
pdf.cell(0, 10, f"{hdr} ({it['start_date']} - {it['end_date']})", 0, 1)
227+
if it.get("details"):
228+
pdf.multi_cell(0, 10, "Highlights: " + ", ".join(it["details"]))
229+
217230

231+
218232
# Certifications
219233
pdf.set_font('Arial', 'B', 12)
220234
pdf.cell(0, 10, "Certifications", 0, 1)
@@ -237,19 +251,7 @@ def generate_pdf():
237251
os.system(f"start {pdf_output_path}" if os.name == "nt" else f"open {pdf_output_path}")
238252
print(f"Resume generated: {pdf_output_path}")
239253

240-
# Internships
241-
if resume_data["internships"]:
242-
pdf.set_font('Arial', 'B', 12)
243-
pdf.cell(0, 10, "Internships", 0, 1)
244-
pdf.set_font('Arial', '', 11)
245-
for it in resume_data["internships"]:
246-
hdr = f"{it['role']} at {it['company']}"
247-
if it.get("location"):
248-
hdr += f" — {it['location']}"
249-
pdf.cell(0, 10, f"{hdr} ({it['start_date']} - {it['end_date']})", 0, 1)
250-
if it.get("details"):
251-
pdf.multi_cell(0, 10, "Highlights: " + ", ".join(it["details"]))
252-
254+
253255

254256
# Main Menu using button_dialog from prompt_toolkit
255257
def interactive_menu():

0 commit comments

Comments
 (0)