Skip to content

Commit 0ce379f

Browse files
committed
.
1 parent f78280a commit 0ce379f

File tree

5 files changed

+13
-3
lines changed

5 files changed

+13
-3
lines changed
27 KB
Loading

โ€Žassets/teams/Ironi Tveria.png

46.4 KB
Loading

โ€Žassets/templates/style.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
caret-color: transparent;
1717
}
1818

19-
@media (max-height: 768px) {
19+
@media (max-height: 900px) {
2020
:root {
2121
--font-size-base: 14px;
2222
--font-size-team-name: 1.8rem;

โ€Žcron.py

+7-2
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,17 @@
11
#!/usr/bin/env python3
22

3+
from pathlib import Path
34
from random import choice
45
import asyncio
56
import datetime
6-
from pathlib import Path
77
import json
88
import os
99
import sys
10+
1011
from dotenv import load_dotenv
12+
1113
from telegram import Bot, constants
14+
from telegram.helpers import escape_markdown
1215

1316
from logger import logger
1417
import web_scrape
@@ -46,6 +49,8 @@ def check_games_today(games):
4649

4750
return False
4851

52+
def escape_markdown_v2(text):
53+
return escape_markdown(text, version=2)
4954

5055
def create_message(*args):
5156
# pylint: disable=unused-variable,too-many-locals
@@ -72,7 +77,7 @@ def create_message(*args):
7277

7378
yield f"""
7479
ืžืฉื—ืง โšฝ *ื”ื™ื•ื* ื‘ืฉืขื” *{game_hour}*
75-
*{league}*: [{home_team}]({home_team_url}) \\|\\| [{guest_team}]({guest_team_url})
80+
*{league}*: [{escape_markdown_v2(home_team)}]({home_team_url}) \\|\\| [{escape_markdown_v2(guest_team)}]({guest_team_url})
7681
ืฆืคื™ ื—ืกื™ืžืช ื›ื‘ื™ืฉื™ื: *{custom_road_block_time}*
7782
ืฆืคื™ ืื•ื”ื“ื™ื ืžืฉื•ืขืจ: *{specs_word}* {custom_sepcs_number}
7883

โ€Žmetadata.py

+5
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,11 @@
7272
"name": "Hapoel Kiryat Shmona",
7373
"url": "https://www.football.co.il/hapoel-kiryat-shmona/",
7474
"logo": "https://static.football.co.il/wp-content/themes/kingclub-theme/images/teams/4563.png",
75+
},
76+
'ืž.ืก. ืืฉื“ื•ื“': {
77+
"name": "Football Club Ashdod",
78+
"url": "https://www.football.co.il/football-club-ashdod/",
79+
"logo": "https://static.football.co.il/wp-content/themes/kingclub-theme/images/teams/4548.png",
7580
}
7681
}
7782

0 commit comments

Comments
ย (0)