File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -379,6 +379,14 @@ def analyze_results(configs, args):
379
379
return regressions
380
380
381
381
382
+ def get_default_output (basename ):
383
+ if 'WORKSPACE' in os .environ :
384
+ workspace = os .environ ['WORKSPACE' ]
385
+ return os .path .join (workspace , basename )
386
+ else :
387
+ return basename
388
+
389
+
382
390
def parse_args ():
383
391
parser = argparse .ArgumentParser ()
384
392
parser .add_argument ('swift_branch' )
@@ -397,7 +405,7 @@ def parse_args():
397
405
action = 'store_true' )
398
406
parser .add_argument ('--output' ,
399
407
type = argparse .FileType ('wb' , 0 ),
400
- default = 'comment.md' )
408
+ default = get_default_output ( 'comment.md' ) )
401
409
parser .add_argument ('--clean' ,
402
410
action = 'store_true' )
403
411
parser .add_argument ('--setup-workspaces-for-pr' ,
You can’t perform that action at this time.
0 commit comments