This commit is contained in:
Marc Beninca 2024-09-17 22:17:41 +02:00
parent 3940d32195
commit e9d228ba2c
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F
2 changed files with 15 additions and 3 deletions

View file

@ -8,7 +8,12 @@ from .debian import Debian
def from_path(path: Path) -> OS:
"""Initialize from an already existing path."""
"""Initialize from an already existing path.
:param path: source root directory
:type path: Path
:rtype: OS
"""
return Debian(path)

View file

@ -10,10 +10,17 @@ class OS(Class, ABC):
"""Operating System."""
def __init__(self, path: Path) -> None:
"""Set root."""
"""Set root.
:param path: root directory
:type path: Path
"""
self.root = path
self.name = self.get_name()
@abstractmethod
def get_name(self) -> str:
"""Return mandatory name."""
"""Return mandatory name.
:rtype: str
"""