movescript/.github/workflows/minify.yml

42 lines
916 B
YAML
Raw Normal View History

2022-12-21 09:49:54 +00:00
name: Minify Scripts
on:
push:
branches: [ "main" ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install Lua
uses: ljmf00/setup-lua@v1.0.0
with:
lua-version: 5.3
install-luarocks: true
- name: Install Minifier
2022-12-21 09:51:42 +00:00
run: wget https://raw.githubusercontent.com/stravant/lua-minify/master/minify.lua
2022-12-21 09:49:54 +00:00
2022-12-21 09:53:39 +00:00
- name: Minify Scripts
run: |
2022-12-21 09:55:33 +00:00
rm -rf min
mkdir min
2022-12-21 09:53:39 +00:00
touch min/movescript.lua
lua minify.lua minify src/movescript.lua > min/movescript.lua
2022-12-21 09:59:55 +00:00
- name: Clean Up Repository
run: |
rm -rf .lua
rm -rf .luarocks
rm -rf .source
rm -f minify.lua
2022-12-21 09:49:54 +00:00
- name: Create Pull Request
uses: peter-evans/create-pull-request@v4