:class:`RM004` ============== .. py:class:: src.ansys.pre_commit_hooks.quality_rules.readme.RM004 Bases: :py:obj:`README` README has a GH-CI badge. Looks for a GitHub Actions workflow badge, a ``badge.svg`` URL under ``github.com///actions/workflows/``. .. rubric:: Notes - A missing badge produces a warning, including when there is no README file. .. !! processed by numpydoc !! .. py:currentmodule:: RM004 Overview -------- .. tab-set:: .. tab-item:: Static methods .. list-table:: :header-rows: 0 :widths: auto * - :py:attr:`~check` - Return whether the README contains a GitHub Actions badge. Import detail ------------- .. code-block:: python from src.ansys.pre_commit_hooks.quality_rules.readme import RM004 Method detail ------------- .. py:method:: check(repository_root: pathlib.Path, readme_file: str | None) -> ansys.pre_commit_hooks.quality_rules.common.RuleCheckResult :staticmethod: Return whether the README contains a GitHub Actions badge. :Parameters: **repository_root** : :obj:`pathlib.Path` Repository root directory. **readme_file** : :class:`python:str` or :data:`python:None` Name of the detected README file, or ``None`` if there is none. :Returns: :ref:`bool ` or :class:`python:str` ``True`` if the badge is found, otherwise a ``"WARNING: ..."`` message. .. !! processed by numpydoc !!