Compare commits

..

3 commits

Author SHA1 Message Date
bdd58e90f2
environ
All checks were successful
/ job (push) Successful in 1m20s
2024-06-10 14:22:07 +02:00
77bc6a0a44
docstrings 2024-06-10 14:12:02 +02:00
0eff166de6
pyproject/ruff 2024-06-10 14:07:56 +02:00
4 changed files with 8 additions and 3 deletions

View file

@ -11,7 +11,7 @@ from cd.projects import Projects
COMMANDS_PREFIX = "cd-"
projects = Projects(os.environ)
projects = Projects()
project = Project(projects)

View file

@ -1,3 +1,4 @@
"""CI project."""
from __future__ import annotations
from pathlib import Path

View file

@ -1,5 +1,7 @@
"""CI projects."""
from __future__ import annotations
import os
from pathlib import Path
GROUP_AND_NAME = [
@ -13,8 +15,8 @@ SERVER_URL = [
class Projects:
def __init__(self: Projects, environment) -> None:
self.environment = environment
def __init__(self: Projects) -> None:
self.environment = os.environ
# group, name
for variable in GROUP_AND_NAME:
if value := self.environment.get(variable, None):

2
pyproject.toml Normal file
View file

@ -0,0 +1,2 @@
[tool.ruff]
select = ["ALL"]