Skip to content

[PB-5334] feature(versioning): cleanup file versions when user loses versioning access #523

[PB-5334] feature(versioning): cleanup file versions when user loses versioning access

[PB-5334] feature(versioning): cleanup file versions when user loses versioning access #523

Workflow file for this run

name: PR Size Check
on:
pull_request:
types: [opened, synchronize]
jobs:
check_pr_size:
runs-on: ubuntu-latest
name: Check PR Size
timeout-minutes: 1
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Get lines changed
run: |
LINES=$(git diff --shortstat origin/${{ github.base_ref }}...HEAD -- . ':!*.spec*' ':!package.json' ':!yarn.lock' | awk '{print $4 + $6}')
echo "Lines changed: $LINES"
echo "LINES_CHANGED=$LINES" >> $GITHUB_ENV
- name: Fail if PR is too big
run: |
if [ "$LINES_CHANGED" -gt 500 ]; then
echo "::error::Large PR ($LINES_CHANGED lines). Please break it down into smaller PRs."
exit 1
else
echo "PR size OK ($LINES_CHANGED lines)"
fi