INNER CODE UNIT · Python

Fore

ImranR98/apps.obtainium.imranr.dev · scripts/generate_from_url.py:17

    class Fore:
        RED = YELLOW = GREEN = BLUE = ""

    print("Note: install colorama for colored output (pip install -r scripts/requirements.txt)")

APP_URL_PREFIX = "obtainium://app/"
APPS_PATH = os.path.abspath(os.path.join(os.path.dirname(__file__), "..", "public", "data", "apps"))
CONFIG_KEYS = ("id", "url", "author", "name")
EXTRA_KEYS = ("preferredApkIndex", "additionalSettings", "overrideSource", "altLabel")
ID_RE = re.compile(r"^[A-Za-z][A-Za-z0-9_]*(\.[A-Za-z0-9_]+)+$")

DRY_RUN = False


def is_obtainium_url(url):
    """Check if the URL is valid."""
    return APP_URL_PREFIX in url

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…