Merge branch 'gzip-html-during-ci' of kazu634/blog into master

This commit is contained in:
Kazuhiro MUSASHI 2020-05-01 01:00:47 +09:00 committed by Gitea
commit 029c98cc86
1 changed files with 2 additions and 4 deletions

View File

@ -17,8 +17,7 @@ steps:
- name: Compress-the-Assets
image: alpine:3.9
commands:
- for TARGET in `find public/ -type f | egrep "\.(css|js|png|jpg|JPG|PNG|CSS|JS)$"`; do gzip -c ${TARGET} > ${TARGET}.gz; done
- for TARGET in `find public/ -type f | egrep "\.(css|js|png|jpg|JPG|PNG|CSS|JS)$"`; do rm -f ${TARGET}; done
- find public/ -type f | egrep "\.(css|js|png|jpg|html|JPG|PNG|CSS|JS|HTML)$" | xargs -n 1 -i% -P 0 sh -c 'cp % %.bk && gzip % && mv %.bk %'
- name: housekeep
image: appleboy/drone-ssh
@ -71,8 +70,7 @@ steps:
- name: Compress-the-Assets
image: alpine:3.9
commands:
- for TARGET in `find public/ -type f | egrep "\.(css|js|png|jpg|JPG|PNG|CSS|JS)$"`; do gzip -c ${TARGET} > ${TARGET}.gz; done
- for TARGET in `find public/ -type f | egrep "\.(css|js|png|jpg|JPG|PNG|CSS|JS)$"`; do rm -f ${TARGET}; done
- find public/ -type f | egrep "\.(css|js|png|jpg|html|JPG|PNG|CSS|JS|HTML)$" | xargs -n 1 -i% -P 0 sh -c 'cp % %.bk && gzip % && mv %.bk %'
- name: housekeep
image: appleboy/drone-ssh