@@ -7,9 +7,6 @@ from pathlib import Path
|
|||||||
import frontmatter
|
import frontmatter
|
||||||
from liquid import Template
|
from liquid import Template
|
||||||
|
|
||||||
# Do not update the format: it's also used to declare groups in the GitHub Actions logs.
|
|
||||||
logging.basicConfig(format="%(message)s", level=logging.INFO)
|
|
||||||
|
|
||||||
# Handle versions having at least 2 digits (ex. 1.2) and at most 4 digits (ex. 1.2.3.4), with an optional leading "v".
|
# Handle versions having at least 2 digits (ex. 1.2) and at most 4 digits (ex. 1.2.3.4), with an optional leading "v".
|
||||||
# Major version must be >= 1.
|
# Major version must be >= 1.
|
||||||
DEFAULT_VERSION_REGEX = r"^v?(?P<major>[1-9]\d*)\.(?P<minor>\d+)(\.(?P<patch>\d+)(\.(?P<tiny>\d+))?)?$"
|
DEFAULT_VERSION_REGEX = r"^v?(?P<major>[1-9]\d*)\.(?P<minor>\d+)(\.(?P<patch>\d+)(\.(?P<tiny>\d+))?)?$"
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ from requests_futures.sessions import FuturesSession
|
|||||||
from urllib3.util import Retry
|
from urllib3.util import Retry
|
||||||
|
|
||||||
# See https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent.
|
# See https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent.
|
||||||
USER_AGENT = 'Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0'
|
USER_AGENT = 'Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/115.0'
|
||||||
|
|
||||||
|
|
||||||
def fetch_urls(urls: list[str], data: any = None, headers: dict[str, str] = None,
|
def fetch_urls(urls: list[str], data: any = None, headers: dict[str, str] = None,
|
||||||
|
|||||||
@@ -4,6 +4,9 @@ import os
|
|||||||
from datetime import datetime, timezone
|
from datetime import datetime, timezone
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
|
# Do not update the format: it's also used to declare groups in the GitHub Actions logs.
|
||||||
|
logging.basicConfig(format="%(message)s", level=logging.INFO)
|
||||||
|
|
||||||
VERSIONS_PATH = Path(os.environ.get("VERSIONS_PATH", "releases"))
|
VERSIONS_PATH = Path(os.environ.get("VERSIONS_PATH", "releases"))
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user