Skip to content

Commit 7db61a5

Browse files
jwpjrdevAndy-Python-Programmer
authored andcommitted
env: prevent unnecessary rebuild
1 parent ba97c5e commit 7db61a5

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

.gitpod.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,4 @@ ports:
1111

1212
tasks:
1313
- init: ./aero.py --test --no-run
14-
# ideally, it wouldn't build a second time
15-
command: ./aero.py --test
14+
command: ./aero.py --only-run

aero.py

+9-1
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,11 @@ def parse_args():
161161
default=False,
162162
action='store_true',
163163
help='doesn\'t run the built image in emulator when applicable')
164+
165+
parser.add_argument('--only-run',
166+
default=False,
167+
action='store_true',
168+
help='runs aero without rebuilding. ignores any build-related flags')
164169

165170
parser.add_argument('--bios',
166171
type=str,
@@ -638,7 +643,10 @@ def main():
638643

639644
download_bundled()
640645

641-
if args.clean:
646+
if args.only_run:
647+
iso_path = os.path.join(BUILD_DIR, 'aero.iso')
648+
run_in_emulator(args, iso_path)
649+
elif args.clean:
642650
src_target = os.path.join('src', 'target', args.target)
643651
userland_target = os.path.join('userland', 'target')
644652

0 commit comments

Comments
 (0)