Skip to content

Add post: The Rich Don't Fine-tune Like You And I #742

Add post: The Rich Don't Fine-tune Like You And I

Add post: The Rich Don't Fine-tune Like You And I #742

name: Enforce WEBP Image Format
on:

Check failure on line 3 in .github/workflows/enforce-webp-only.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/enforce-webp-only.yml

Invalid workflow file

You have an error in your yaml syntax on line 3
pull_request:
paths:
- '**.png'
- '**.jpg'
- '**.jpeg'
- '**.gif'
- '**.bmp'
- '**.tiff'
- '**.ico'
jobs:
check-images:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Check for non-WEBP images
run: |
files=$(git diff --name-only ${{ github.event.before }} ${{
github.sha }} -- '*.png' '*.jpg' '*.jpeg' '*.gif' '*.bmp' '*.tiff' '*.ico')
if [ -n "$files" ]; then
echo "The following non-WEBP image files have been found in the
pull request:"
echo "$files"
exit 1
else
echo "No non-WEBP images found. Proceeding..."
fi