@@ -25,10 +25,25 @@ jobs:
2525 pull-requests : write
2626 steps :
2727 - name : Checkout
28+ if : github.event_name != 'issue_comment'
2829 uses : actions/checkout@master
2930 with :
3031 submodules : recursive
32+
33+ - name : Resolve PR refs (Issue)
34+ if : ${{ github.event_name == 'issue_comment' }}
35+ id : refs
36+ uses : arqu/resolve-pr-refs@main
37+ with :
38+ token : ${{ secrets.GITHUB_TOKEN }}
3139
40+ - name : Checkout
41+ if : github.event_name == 'issue_comment'
42+ uses : actions/checkout@master
43+ with :
44+ submodules : recursive
45+ ref : steps.refs.outputs.head_ref
46+
3247 - name : Install rust stable
3348 uses : dtolnay/rust-toolchain@stable
3449
@@ -97,12 +112,7 @@ jobs:
97112 run : |
98113 echo "LAST_COMMIT_SHA=unknown" >> ${GITHUB_ENV}
99114 echo "HEAD_REF=unknown" >> ${GITHUB_ENV}
100- - name : Resolve PR refs (Issue)
101- if : ${{ github.event_name == 'issue_comment' }}
102- id : refs
103- uses : arqu/resolve-pr-refs@main
104- with :
105- token : ${{ secrets.GITHUB_TOKEN }}
115+
106116 - name : Setup Environment (Issue)
107117 if : ${{ github.event_name == 'issue_comment' }}
108118 shell : bash
@@ -169,7 +179,7 @@ jobs:
169179 curl -X POST -H "Content-Type: text/plain" --data "$prom_data" ${{secrets.PROM_ENDPOINT}}/metrics/job/netsim/instance/${instance}
170180
171181 - name : Post metrics
172- if : github.ref_name=='main'
182+ if : github.ref_name=='main' && github.event_name != 'issue_comment'
173183 run : |
174184 cd chuck/netsim
175185 d=$(cat report_metro.txt)
0 commit comments