From 52231a5b2f7b2e942a2cd8e2d6d0935777491150 Mon Sep 17 00:00:00 2001 From: Liudon Date: Sun, 29 Sep 2024 20:54:27 +0800 Subject: [PATCH] Update main.yml --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 7e86fb3fa..969edf920 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -51,7 +51,7 @@ jobs: - name: Compress Image uses: jruipinto/ImageMagick-action@v1 with: - command: find ./content/posts/ -type f $ -iname "*.jpg" -o -iname "*.jpeg" -o -iname "*.png" $ -exec sh -c 'for img; do convert "$img" "${img%.*}.webp" && convert "$img" "${img%.*}.avif"; done' _ {} + + command: find ./content/posts/ -type f \( -name "*.jpg" -o -name "*.png" -o -name "*.jpeg" \) -exec convert {} {}.webp && convert {} {}.avif \; github_pages: name: Build and Publish Github Pages