mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-29 17:47:14 +02:00
Dump only "platform, board and framework" by default when processing environment
This commit is contained in:
@ -99,7 +99,7 @@ def LoadPioPlatform(env, variables):
|
||||
|
||||
|
||||
def PrintConfiguration(env): # pylint: disable=too-many-branches
|
||||
platform_data = ["Platform: %s ::" % env.PioPlatform().title]
|
||||
platform_data = ["Platform: %s >" % env.PioPlatform().title]
|
||||
system_data = ["System:"]
|
||||
mcu = env.subst("$BOARD_MCU")
|
||||
f_cpu = env.subst("$BOARD_F_CPU")
|
||||
|
@ -215,12 +215,12 @@ def CheckUploadSize(_, target, source, env): # pylint: disable=W0613,W0621
|
||||
|
||||
def PrintUploadInfo(env):
|
||||
configured = env.subst("$UPLOAD_PROTOCOL")
|
||||
available = []
|
||||
available = [configured] if configured else []
|
||||
if "BOARD" in env:
|
||||
available = env.BoardConfig().get("upload", {}).get(
|
||||
"protocols", [configured])
|
||||
available.extend(env.BoardConfig().get("upload", {}).get(
|
||||
"protocols", []))
|
||||
if available:
|
||||
print "Available: %s" % ", ".join(available)
|
||||
print "Available: %s" % ", ".join(sorted(available))
|
||||
if configured:
|
||||
print "Configured: upload_protocol = %s" % configured
|
||||
|
||||
|
@ -124,6 +124,8 @@ def cli(ctx, environment, target, upload_port, project_dir, silent, verbose,
|
||||
|
||||
class EnvironmentProcessor(object):
|
||||
|
||||
DEFAULT_DUMP_OPTIONS = ("platform", "framework", "board")
|
||||
|
||||
KNOWN_OPTIONS = ("platform", "framework", "board", "board_mcu",
|
||||
"board_f_cpu", "board_f_flash", "board_flash_mode",
|
||||
"build_flags", "src_build_flags", "build_unflags",
|
||||
@ -176,19 +178,19 @@ class EnvironmentProcessor(object):
|
||||
def process(self):
|
||||
terminal_width, _ = click.get_terminal_size()
|
||||
start_time = time()
|
||||
env_dump = []
|
||||
|
||||
for k, v in self.options.items():
|
||||
self.options[k] = self.options[k].strip()
|
||||
if self.verbose or k in self.DEFAULT_DUMP_OPTIONS:
|
||||
env_dump.append(
|
||||
"%s: %s" % (k, ", ".join(util.parse_conf_multi_values(v))))
|
||||
|
||||
if not self.silent:
|
||||
click.echo("[%s] Processing %s (%s)" %
|
||||
(datetime.now().strftime("%c"),
|
||||
click.style(self.name, fg="cyan", bold=True),
|
||||
"; ".join([
|
||||
"%s: %s" %
|
||||
(k, ", ".join(util.parse_conf_multi_values(v)))
|
||||
for k, v in self.options.items()
|
||||
])))
|
||||
"; ".join(env_dump)))
|
||||
click.secho("-" * terminal_width, bold=True)
|
||||
|
||||
self.options = self._validate_options(self.options)
|
||||
|
Reference in New Issue
Block a user