Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create filesize check #101

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/filesize.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: File size check
on: [pull_request]
jobs:
File-Size:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
with:
fetch-depth: 2
- name: check size
shell: bash
run: |
CHANGED=`git diff --name-only -r HEAD^1 HEAD`
FAIL=0
while IFS= read -r line; do
SIZE=`find -maxdepth 1 -name "$line" -not -name '*.drawio' -size +2M`
if [ "$SIZE" ]; then
echo -n "File too large: " `du -h $line`
FAIL=1
fi
done <<< "$CHANGED"
exit $FAIL
13,165 changes: 0 additions & 13,165 deletions blueprints/multi-oe/design/OCI_Open_LZ_Multi-OE-Blueprint.drawio

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
6268bd1c91ecbe6145b5d2a0342f1552806a927c
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
58c10005e3ba4f67bc2bbc7edf4209e308055a92
20,879 changes: 0 additions & 20,879 deletions blueprints/one-oe/design/OCI_Open_LZ_One-OE-Blueprint.drawio

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
864d77e8342431f9bd28adb932409f1f503a5e28