Skip to content

Commit

Permalink
Update compile_schedule.py
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremymanning authored Jul 18, 2024
1 parent 2d34cfa commit 2464678
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion compile_schedule.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,22 @@
import os
from datetime import datetime
import re
from emoji_mapping import emoji_mapping # Import the emoji mapping
import csv

# Function to load emoji mapping from CSV
def load_emoji_mapping(csv_file):
emoji_mapping = {}
with open(csv_file, 'r', encoding='utf-8') as file:
reader = csv.DictReader(file)
for row in reader:
# Handle multiple unicode codes by splitting them
emoji_codes = row['Emoji'].split()
for code in emoji_codes:
emoji_mapping[code] = row['Name']
return emoji_mapping

# Load emoji mapping
emoji_mapping = load_emoji_mapping('emoji_mapping.csv')

# Determine the term and year
def get_term_and_year(start_date):
Expand Down

0 comments on commit 2464678

Please sign in to comment.