1
0
Fork 0
mirror of https://github.com/SunRed/theme-dark-arc-gitea.git synced 2024-10-22 15:06:13 +02:00

Merge pull request #13 from SunRed/github-actions

Add css minifier action
This commit is contained in:
Jake G 2024-06-27 11:28:21 -07:00 committed by GitHub
commit 7587229d43
Signed by: GitHub
GPG key ID: B5690EEEBB952194
2 changed files with 28 additions and 1 deletions

27
.github/workflows/minify.yml vendored Normal file
View file

@ -0,0 +1,27 @@
on:
push:
branches:
- 'main'
paths:
- 'theme-dark-arc.css'
workflow_dispatch:
jobs:
minify:
runs-on: ubuntu-latest
steps:
- name: check out the repository
uses: actions/checkout@v4
- name: auto minify the files
uses: nizarmah/auto-minify@v3
with:
overwrite: false
maxdepth: 1
- name: auto commit the minified files
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "bot: Minify theme"
file_pattern: '*.min.css'
branch: ${{ github.ref }}

View file

@ -33,7 +33,7 @@ Create `/public/assets/css` below your $GITEA_CUSTOM path, MY custom path is `/v
sudo mkdir -p /var/lib/gitea/custom/public/assets/css
cd /var/lib/gitea/custom/public/assets/css
wget https://raw.githubusercontent.com/Jieiku/theme-dark-arc-gitea/main/theme-dark-arc.css
curl -o theme-dark-arc.css https://raw.githubusercontent.com/Jieiku/theme-dark-arc-gitea/main/theme-dark-arc.min.css
## Make sure ownership is correct: