sanity: Load arguments from files
Python module argparse has a feature to load arguments from a file. This commit enables such feature on sanitycheck script so files prefixed by + (plus sign) are loaded during argument parsing stage and included as arguments to such script. Jira: ZEP-122 Change-Id: Ibb0a6e8464218a4f58ce4044a5a0860dc5b32480 Signed-off-by: Genaro Saucedo Tejada <genaro.saucedo.tejada@intel.com>
This commit is contained in:
parent
2901f89170
commit
28bba92dc0
3 changed files with 11 additions and 0 deletions
3
scripts/sanity_chk/sanity_daily.args
Normal file
3
scripts/sanity_chk/sanity_daily.args
Normal file
|
@ -0,0 +1,3 @@
|
|||
--inline-logs
|
||||
--all
|
||||
--enable-slow
|
3
scripts/sanity_chk/sanity_verify.args
Normal file
3
scripts/sanity_chk/sanity_verify.args
Normal file
|
@ -0,0 +1,3 @@
|
|||
--inline-logs
|
||||
--exclude-tag
|
||||
footprint
|
|
@ -150,6 +150,10 @@ Metrics (such as pass/fail state and binary size) for the last code
|
|||
release are stored in scripts/sanity_chk/sanity_last_release.csv.
|
||||
To update this, pass the --all --release options.
|
||||
|
||||
To load arguments from a file, write '+' before the file name, e.g.,
|
||||
+file_name. File content must be one or more valid arguments separated by
|
||||
line break instead of white spaces.
|
||||
|
||||
Most everyday users will run with no arguments.
|
||||
"""
|
||||
|
||||
|
@ -1607,6 +1611,7 @@ def parse_arguments():
|
|||
|
||||
parser = argparse.ArgumentParser(description = __doc__,
|
||||
formatter_class = argparse.RawDescriptionHelpFormatter)
|
||||
parser.fromfile_prefix_chars = "+"
|
||||
|
||||
parser.add_argument("-p", "--platform", action="append",
|
||||
help="Platform filter for testing. This option may be used multiple "
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue