generated from keep-starknet-strange/alexandria
-
Notifications
You must be signed in to change notification settings - Fork 81
43 lines (34 loc) · 1.06 KB
/
gas_reports.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Compare Snapshot
on: pull_request
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
pull-requests: write
jobs:
compare-snapshot:
permissions: write-all
# trunk-ignore(actionlint/runner-label)
runs-on: ubuntu-latest-16-cores
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Set up Scarb
uses: software-mansion/setup-scarb@v1
- name: Run compare_snapshot script
id: run-script
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
continue-on-error: true
run: |
result=$(python scripts/compare_snapshot.py 2>&1)
status=$(echo "$result" | tail -n 1 | awk -F ':' '{print $1}')
echo "$result" >> "$GITHUB_STEP_SUMMARY"
echo "status=$status" >> "$GITHUB_OUTPUT"
- name: Exit step based on status
if: steps.run-script.outputs.status == 'ERROR'
run: exit 1