Skip to content

Commit

Permalink
Test stateful shell
Browse files Browse the repository at this point in the history
  • Loading branch information
aBozowski committed May 27, 2022
1 parent ecd2d00 commit 07db659
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions examples/chef/chef.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,10 +283,10 @@ def main(argv: Sequence[str]) -> None:
except KeyError:
flush_print("MISSING DEVICE CACHE - "+fix_instructions)
exit(1)
if device == "zap_commit" and False:
# Disabled; should check:
# Current branch when writing manifest
# Master in CI
if device == "zap_commit" and False:
if cached_manifest[device] != ci_manifest[device]:
flush_print("BAD ZAP VERSION - "+fix_instructions)
exit(1)
Expand Down Expand Up @@ -349,11 +349,13 @@ def main(argv: Sequence[str]) -> None:
#

if options.ci:
if options.build_target == "nrfconnect":
os.environ['GNUARMEMB_TOOLCHAIN_PATH'] = os.environ['PW_ARM_CIPD_INSTALL_DIR']
# if options.build_target == "nrfconnect":
# os.environ['GNUARMEMB_TOOLCHAIN_PATH'] = os.environ['PW_ARM_CIPD_INSTALL_DIR']
for device_name in [d for d in _DEVICE_LIST if d in _CI_ALLOW_LIST]:
command = f"./chef.py -cbr --use_zzz -d {device_name} -t {options.build_target}"
subprocess.check_call(command, cwd=_CHEF_SCRIPT_PATH, shell=True)
shell.run_cmd("export GNUARMEMB_TOOLCHAIN_PATH=\"$PW_ARM_CIPD_INSTALL_DIR\"")
shell.run_cmd("./chef.py -cbr --use_zzz -d {device_name} -t {options.build_target}")
# command = f"./chef.py -cbr --use_zzz -d {device_name} -t {options.build_target}"
# subprocess.check_call(command, cwd=_CHEF_SCRIPT_PATH, shell=True)
exit(0)

#
Expand All @@ -362,7 +364,9 @@ def main(argv: Sequence[str]) -> None:

if options.build_all:
# Needs testing after refactor
# Needs to call per-platform bundle function before use
# Needs to call per-platform bundle function
flush_print("Build all disabled")
exit(1)
flush_print("Building all chef examples")
os.environ['GNUARMEMB_TOOLCHAIN_PATH'] = os.environ['PW_ARM_CIPD_INSTALL_DIR']
archive_prefix = "/workspace/artifacts/"
Expand Down

0 comments on commit 07db659

Please sign in to comment.