tik_manager4.objects.main ========================= .. py:module:: tik_manager4.objects.main .. autoapi-nested-parse:: Main Module for the Tik Manager Classes ------- .. autoapisummary:: tik_manager4.objects.main.Main tik_manager4.objects.main.ReleaseObject Module Contents --------------- .. py:class:: Main(common_folder=None) Main Tik Manager class. Handles User and Project related functions. .. py:method:: add_project_as_structure_template(template_name=None) Add the current project as a new structure template. .. py:method:: can_set_project(absolute_path) -> tik_manager4.core.constants.ValidationResult Check if the project is valid. Args: absolute_path (str): The absolute path to the project. Returns: object: ValidationResult object. .. py:method:: collect_template_paths() Collect all template files from common, project and user folders. Returns: list: [project_templates, common_templates, user_templates] .. py:method:: create_project(path, structure_template='empty', structure_data=None, set_after_creation=True, locked_commons=True, **kwargs) Create a new project. Args: path (str): The path to create the project. structure_template (str): The name of the structure template to use. structure_data (dict): The structure data to use. If not provided, The structure template name will be used to get the data from the common database. set_after_creation (bool): If True, the project will be set after creation. locked_commons (bool): If True, the project will be locked to the current commons. Returns: int: 1 if successful, -1 if not. .. py:method:: fallback_to_default_project() Fallback to the default project. .. py:method:: get_latest_release() Get the latest release version from the github repository. Returns: ReleaseObject: Release object with version and download links. .. py:method:: get_management_handler(platform_name=None) Resolve the management handler. Args: platform_name (str, optional): The name of the platform. if the platform name is not matching to the current one, a new handler will be created. .. py:method:: get_template_names() Get the names of the templates. .. py:method:: get_template_path_by_name(name) Gets the template file by name. Resolution order is project > common > user. Args: name (str): Name of the template. Returns: tuple: Dcc Name, Path to the template file. .. py:method:: globalize_management_platform() Globalize the management platform. .. py:method:: set_project(absolute_path) Set the current project. Args: absolute_path (str): The absolute path to the project. Returns: int: 1 if successful, -1 if not. .. py:attribute:: dcc .. py:attribute:: log .. py:class:: ReleaseObject(github_dict) Data class for the update object. .. py:method:: collect_links() Get all the links in a dictionary. Returns: dict: Dictionary with the link names and the links. .. py:property:: debian_installer Get the linux installer download url. Returns: str: The download url or None. .. py:property:: is_newer Check if the current version is newer than the installed version. .. py:property:: mac_installer Get the mac installer download url. Returns: str: The download url or None. .. py:property:: name Get the name. .. py:property:: redhat_installer Get the linux installer download url. Returns: str: The download url or None. .. py:property:: release_notes Return the release notes. .. py:property:: tarball Return the tarball. .. py:property:: version Get the version. .. py:property:: windows_installer Get the windows installer download url. Returns: str: The download url or None. .. py:property:: zipball Return the zipball.