mirror of
https://git.yoctoproject.org/poky
synced 2026-05-30 00:20:08 +00:00
wic: use wic logger in core modules
Replaced msger with wic logger in the core wic modules. (From OE-Core rev: cdd6675951b74075c9b9159f7465a88f83775bac) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
58ff06f1e7
commit
fe2d602240
@@ -30,8 +30,10 @@ import logging
|
||||
|
||||
from wic.plugin import pluginmgr, PLUGIN_TYPES
|
||||
|
||||
logger = logging.getLogger('wic')
|
||||
|
||||
def subcommand_error(args):
|
||||
logging.info("invalid subcommand %s", args[0])
|
||||
logger.info("invalid subcommand %s", args[0])
|
||||
|
||||
|
||||
def display_help(subcommand, subcommands):
|
||||
@@ -81,13 +83,13 @@ def invoke_subcommand(args, parser, main_command_usage, subcommands):
|
||||
Should use argparse, but has to work in 2.6.
|
||||
"""
|
||||
if not args:
|
||||
logging.error("No subcommand specified, exiting")
|
||||
logger.error("No subcommand specified, exiting")
|
||||
parser.print_help()
|
||||
return 1
|
||||
elif args[0] == "help":
|
||||
wic_help(args, main_command_usage, subcommands)
|
||||
elif args[0] not in subcommands:
|
||||
logging.error("Unsupported subcommand %s, exiting\n", args[0])
|
||||
logger.error("Unsupported subcommand %s, exiting\n", args[0])
|
||||
parser.print_help()
|
||||
return 1
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user