Module continuous_delivery_scripts.plugins.noop
No Operation plugin.
Expand source code
#
# Copyright (C) 2020-2025 Arm Limited or its affiliates and Contributors. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
#
"""No Operation plugin."""
import logging
from pathlib import Path
from typing import Optional, Dict
from continuous_delivery_scripts.spdx_report.spdx_project import SpdxProject
from continuous_delivery_scripts.utils.definitions import CommitType
from continuous_delivery_scripts.utils.git_helpers import GitWrapper
from continuous_delivery_scripts.utils.language_specifics_base import BaseLanguage, get_language_from_file_name
logger = logging.getLogger(__name__)
class NoOp(BaseLanguage):
"""Specific actions for a NoOp project."""
def get_related_language(self) -> str:
"""Gets the related language."""
return get_language_from_file_name(__file__)
def package_software(self, mode: CommitType, version: str) -> None:
"""No Op."""
pass
def release_package_to_repository(self, mode: CommitType, version: str) -> None:
"""No Op."""
pass
def check_credentials(self) -> None:
"""No Op."""
pass
def generate_code_documentation(self, output_directory: Path, module_to_document: str) -> None:
"""No Op."""
pass
def can_add_licence_headers(self) -> bool:
"""No Op."""
return False
def can_get_project_metadata(self) -> bool:
"""No Op."""
"""States whether project metadata can be retrieved."""
return False
def get_current_spdx_project(self) -> Optional[SpdxProject]:
"""No Op."""
return None
def tag_release(self, git: GitWrapper, version: str, shortcuts: Dict[str, bool]) -> None:
"""Tags release commit."""
pass
Classes
class NoOp
-
Specific actions for a NoOp project.
Expand source code
class NoOp(BaseLanguage): """Specific actions for a NoOp project.""" def get_related_language(self) -> str: """Gets the related language.""" return get_language_from_file_name(__file__) def package_software(self, mode: CommitType, version: str) -> None: """No Op.""" pass def release_package_to_repository(self, mode: CommitType, version: str) -> None: """No Op.""" pass def check_credentials(self) -> None: """No Op.""" pass def generate_code_documentation(self, output_directory: Path, module_to_document: str) -> None: """No Op.""" pass def can_add_licence_headers(self) -> bool: """No Op.""" return False def can_get_project_metadata(self) -> bool: """No Op.""" """States whether project metadata can be retrieved.""" return False def get_current_spdx_project(self) -> Optional[SpdxProject]: """No Op.""" return None def tag_release(self, git: GitWrapper, version: str, shortcuts: Dict[str, bool]) -> None: """Tags release commit.""" pass
Ancestors
- BaseLanguage
- abc.ABC
Methods
def can_add_licence_headers(self) ‑> bool
-
No Op.
Expand source code
def can_add_licence_headers(self) -> bool: """No Op.""" return False
def can_get_project_metadata(self) ‑> bool
-
No Op.
Expand source code
def can_get_project_metadata(self) -> bool: """No Op.""" """States whether project metadata can be retrieved.""" return False
def check_credentials(self) ‑> None
-
No Op.
Expand source code
def check_credentials(self) -> None: """No Op.""" pass
def generate_code_documentation(self, output_directory: pathlib.Path, module_to_document: str) ‑> None
-
No Op.
Expand source code
def generate_code_documentation(self, output_directory: Path, module_to_document: str) -> None: """No Op.""" pass
def get_current_spdx_project(self) ‑> Optional[SpdxProject]
-
No Op.
Expand source code
def get_current_spdx_project(self) -> Optional[SpdxProject]: """No Op.""" return None
-
Gets the related language.
Expand source code
def get_related_language(self) -> str: """Gets the related language.""" return get_language_from_file_name(__file__)
def package_software(self, mode: CommitType, version: str) ‑> None
-
No Op.
Expand source code
def package_software(self, mode: CommitType, version: str) -> None: """No Op.""" pass
def release_package_to_repository(self, mode: CommitType, version: str) ‑> None
-
No Op.
Expand source code
def release_package_to_repository(self, mode: CommitType, version: str) -> None: """No Op.""" pass
Inherited members