import platform
import re


def sanitize_app_name(name):
    """
    App names can contain characters that are invalid for file system paths.
    This function attempts to sanitize them depending on the platform.
    """

    if platform.system() == "Windows":
        return re.sub(r'[<>:"/\\|?*]', '', name)
    else:
        # assume unix-like if platform is not windows
        return re.sub(r'[/]', '', name)