move FlakeId to flake id

move FlakeId to flake id
This commit is contained in:
Jörg Thalheim
2024-07-03 13:03:40 +02:00
parent f5831f744c
commit 6037ad1ce0
30 changed files with 91 additions and 93 deletions

View File

@@ -2,7 +2,6 @@ import argparse
import importlib
import logging
from ..clan_uri import FlakeId
from ..completions import add_dynamic_completer, complete_machines
from ..machines.machines import Machine
@@ -50,7 +49,7 @@ def check_secrets(machine: Machine, service: None | str = None) -> bool:
def check_command(args: argparse.Namespace) -> None:
machine = Machine(
name=args.machine,
flake=FlakeId(args.flake),
flake=args.flake,
)
check_secrets(machine, service=args.service)

View File

@@ -3,7 +3,6 @@ import importlib
import json
import logging
from ..clan_uri import FlakeId
from ..completions import add_dynamic_completer, complete_machines
from ..machines.machines import Machine
@@ -27,7 +26,7 @@ def get_all_facts(machine: Machine) -> dict:
def get_command(args: argparse.Namespace) -> None:
machine = Machine(name=args.machine, flake=FlakeId(args.flake))
machine = Machine(name=args.machine, flake=args.flake)
# the raw_facts are bytestrings making them not json serializable
raw_facts = get_all_facts(machine)

View File

@@ -4,7 +4,6 @@ import logging
from pathlib import Path
from tempfile import TemporaryDirectory
from ..clan_uri import FlakeId
from ..cmd import Log, run
from ..completions import add_dynamic_completer, complete_machines
from ..machines.machines import Machine
@@ -45,7 +44,7 @@ def upload_secrets(machine: Machine) -> None:
def upload_command(args: argparse.Namespace) -> None:
machine = Machine(name=args.machine, flake=FlakeId(args.flake))
machine = Machine(name=args.machine, flake=args.flake)
upload_secrets(machine)