devops.config

DevOps config package.

class devops.config.Constants(github=GitConstants(github_url='https://github.com', github_devops_repo='https://github.com/97gamjak/devops', github_devops_issues_url='https://github.com/97gamjak/devops/issues', github_default_owner_url='https://github.com/repo/owner'), files=FileConstants(default_toml_template='devops.toml.template', toml_filenames=['devops.toml', '.devops.toml']))[source]

Bases: object

Class holding constant values for DevOps checks.

Parameters:
github: GitConstants = GitConstants(github_url='https://github.com', github_devops_repo='https://github.com/97gamjak/devops', github_devops_issues_url='https://github.com/97gamjak/devops/issues', github_default_owner_url='https://github.com/repo/owner')
files: FileConstants = FileConstants(default_toml_template='devops.toml.template', toml_filenames=['devops.toml', '.devops.toml'])
class devops.config.CppConfig(style_checks=True, license_header_check=True, license_header=None, check_only_staged_files=False, header_guards_according_to_filepath=False)[source]

Bases: object

Dataclass to hold C++ configuration values.

Parameters:
  • style_checks (bool)

  • license_header_check (bool)

  • license_header (str | None)

  • check_only_staged_files (bool)

  • header_guards_according_to_filepath (bool)

style_checks: bool = True
license_header_check: bool = True
license_header: str | None = None
check_only_staged_files: bool = False
header_guards_according_to_filepath: bool = False
to_toml_lines()[source]

Convert the CppConfig to TOML lines.

Returns:

list[str] – The list of TOML lines representing the configuration.

Return type:

list[str]

class devops.config.GitConfig(tag_prefix='', empty_tag_list_allowed=True)[source]

Bases: object

Dataclass to hold default git configuration values.

Parameters:
  • tag_prefix (str)

  • empty_tag_list_allowed (bool)

tag_prefix: str = ''
empty_tag_list_allowed: bool = True
to_toml_lines()[source]

Convert the GitConfig to TOML lines.

Returns:

list[str] – The list of TOML lines representing the configuration.

Return type:

list[str]

devops.config.init_config()[source]

Initialize global config paths.

Returns:

GlobalConfig – The initialized global configuration object.

Return type:

GlobalConfig

Modules

base

Base configuration utilities.

config

Module for reading and parsing configuration files.

config_cpp

Module for parsing C++ configuration.

config_file

Module to parse file configuration values.

config_git

Git configuration parsing module.

config_logging

Module for logging configuration.

constants

Constants for DevOps checks.

toml

Module for handling TOML files in a DevOps context.