organized imports
This commit is contained in:
parent
70b04f039a
commit
1bd547587b
13 changed files with 28 additions and 8 deletions
|
@ -1,6 +1,9 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
|
# system
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
|
# local
|
||||||
import kiwi
|
import kiwi
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
# local
|
||||||
from .parser import Parser
|
from .parser import Parser
|
||||||
from .runner import Runner
|
from .runner import Runner
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
# system
|
||||||
import os
|
import os
|
||||||
|
|
||||||
KIWI_ROOT = os.getenv('KIWI_ROOT', ".")
|
KIWI_ROOT = os.getenv('KIWI_ROOT', ".")
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
|
# system
|
||||||
import copy
|
import copy
|
||||||
import logging
|
import logging
|
||||||
import re
|
|
||||||
import os
|
import os
|
||||||
|
import re
|
||||||
import yaml
|
import yaml
|
||||||
|
|
||||||
|
# local
|
||||||
from ._constants import KIWI_ROOT, KIWI_CONF_NAME
|
from ._constants import KIWI_ROOT, KIWI_CONF_NAME
|
||||||
|
|
||||||
###########
|
###########
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
# system
|
||||||
import argparse
|
import argparse
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
|
# system
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
|
# local
|
||||||
from .config import LoadedConfig
|
from .config import LoadedConfig
|
||||||
from .parser import Parser
|
from .parser import Parser
|
||||||
from .subcommands import *
|
from .subcommands import *
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
|
# local
|
||||||
from .init import InitCommand
|
from .init import InitCommand
|
||||||
from .show import ShowCommand
|
|
||||||
from .logs import LogsCommand
|
from .logs import LogsCommand
|
||||||
|
from .show import ShowCommand
|
||||||
|
|
||||||
__all__ = [
|
__all__ = [
|
||||||
'InitCommand',
|
'InitCommand',
|
||||||
'ShowCommand',
|
'LogsCommand',
|
||||||
'LogsCommand'
|
'ShowCommand'
|
||||||
]
|
]
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
# parent
|
||||||
from ..parser import Parser
|
from ..parser import Parser
|
||||||
|
|
||||||
|
|
||||||
|
@ -14,5 +15,3 @@ class SubCommand:
|
||||||
|
|
||||||
def run(self, config, args):
|
def run(self, config, args):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
|
# system
|
||||||
import logging
|
import logging
|
||||||
import os
|
import os
|
||||||
|
|
||||||
|
# parent (display purposes only)
|
||||||
from .._constants import KIWI_CONF_NAME
|
from .._constants import KIWI_CONF_NAME
|
||||||
from ..config import DefaultConfig
|
|
||||||
|
|
||||||
|
# local
|
||||||
from ._subcommand import SubCommand
|
from ._subcommand import SubCommand
|
||||||
|
|
||||||
|
|
||||||
|
@ -37,6 +39,8 @@ class InitCommand(SubCommand):
|
||||||
logging.info(f"Initializing kiwi-config instance in '{os.getcwd()}'")
|
logging.info(f"Initializing kiwi-config instance in '{os.getcwd()}'")
|
||||||
|
|
||||||
if args.force and os.path.isfile(KIWI_CONF_NAME):
|
if args.force and os.path.isfile(KIWI_CONF_NAME):
|
||||||
|
from ..config import DefaultConfig
|
||||||
|
|
||||||
logging.warning(f"Overwriting existing '{KIWI_CONF_NAME}'!")
|
logging.warning(f"Overwriting existing '{KIWI_CONF_NAME}'!")
|
||||||
config = DefaultConfig.get()
|
config = DefaultConfig.get()
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
|
# system
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
|
# local
|
||||||
from ._subcommand import SubCommand
|
from ._subcommand import SubCommand
|
||||||
from .utils.dockercommand import DockerCommand
|
from .utils.dockercommand import DockerCommand
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
# local
|
||||||
from ._subcommand import SubCommand
|
from ._subcommand import SubCommand
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
|
# system
|
||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
|
# local
|
||||||
from .executable import Executable
|
from .executable import Executable
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
import os
|
# system
|
||||||
import logging
|
import logging
|
||||||
|
import os
|
||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue