mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-01 10:40:47 +03:00
Merge branch 'bugfix/parttool-extra-partition-subtypes-eat-all' into 'master'
fix(partition_table): restore multi-value --extra-partition-subtypes parsing See merge request espressif/esp-idf!50287
This commit is contained in:
@@ -20,6 +20,7 @@ import struct
|
||||
import sys
|
||||
|
||||
import rich_click as click
|
||||
from esp_pylib.cli_options import OptionEatAll
|
||||
from esp_pylib.cli_types import AnyIntType
|
||||
from esp_pylib.logger import log
|
||||
|
||||
@@ -793,7 +794,16 @@ def run_gen(
|
||||
default=None,
|
||||
help='Require app partitions to be suitable for secure boot',
|
||||
)
|
||||
@click.option('--extra-partition-subtypes', multiple=True, help='Extra partition subtype entries')
|
||||
# Use OptionEatAll to keep argparse nargs='*' semantics: a single
|
||||
# --extra-partition-subtypes flag consumes all following space-separated
|
||||
# entries (CMake partition_table/CMakeLists.txt passes them this way).
|
||||
@click.option(
|
||||
'--extra-partition-subtypes',
|
||||
multiple=True,
|
||||
cls=OptionEatAll,
|
||||
type=str,
|
||||
help='Extra partition subtype entries',
|
||||
)
|
||||
@click.argument('input_file', type=click.File('rb'), metavar='INPUT')
|
||||
@click.argument('output', type=click.Path(), required=False, default='-')
|
||||
def cli(
|
||||
|
||||
@@ -270,7 +270,16 @@ def _partition_selection_options(func):
|
||||
help='select the default boot partition using the same fallback logic as the IDF bootloader',
|
||||
),
|
||||
click.option('--partition-subtype', '-s', help='subtype of the partition'),
|
||||
click.option('--extra-partition-subtypes', multiple=True, help='Extra partition subtype entries'),
|
||||
# Use OptionEatAll to keep argparse nargs='*' semantics: a single
|
||||
# --extra-partition-subtypes flag consumes all following space-separated
|
||||
# entries (CMake project_include.cmake passes them this way).
|
||||
click.option(
|
||||
'--extra-partition-subtypes',
|
||||
multiple=True,
|
||||
cls=OptionEatAll,
|
||||
type=str,
|
||||
help='Extra partition subtype entries',
|
||||
),
|
||||
]
|
||||
for decorator in reversed(decorators):
|
||||
func = decorator(func)
|
||||
|
||||
Reference in New Issue
Block a user