Skip to content

Commit 66c7114

Browse files
Use GitHub Action to resize and compress images
1 parent 67a0e9a commit 66c7114

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

.github/workflows/optimize-images.yml

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: Optimize Images
2+
on: push
3+
4+
jobs:
5+
optimize-images:
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/checkout@v2
9+
with:
10+
ref: ${{ github.head_ref }}
11+
- uses: namoscato/action-tinify@v1
12+
with:
13+
api_key: ${{ secrets.TINIFY_API_KEY }}
14+
github_token: ${{ secrets.GITHUB_TOKEN }}
15+
resize_width: 1920
16+
resize_height: 1920

0 commit comments

Comments
 (0)