prettied up the output sent to discord
This commit is contained in:
@ -94,7 +94,9 @@ def send_to_discord_webhook(data, webhook_url):
|
|||||||
other_events = [e for e in data if not is_pub_event(e)]
|
other_events = [e for e in data if not is_pub_event(e)]
|
||||||
# Format as plain grouped messages
|
# Format as plain grouped messages
|
||||||
def format_batch(events, title):
|
def format_batch(events, title):
|
||||||
content = f"**{title}**\n"
|
import datetime
|
||||||
|
today = datetime.datetime.now().strftime('%Y-%m-%d')
|
||||||
|
content = f"## {today}\n**{title}**\n"
|
||||||
for item in events:
|
for item in events:
|
||||||
content += (
|
content += (
|
||||||
f"> **{item['nation']}**\n"
|
f"> **{item['nation']}**\n"
|
||||||
|
|||||||
Reference in New Issue
Block a user