Skip to content

Workflow file for this run

name: Build Magisk/KernelSU Module
on:
push:
tags: [ v*.*.* ]
jobs:
build:
name: Build Module
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Apt Dependencies
run: |
sudo apt update -y && sudo apt upgrade -y
sudo apt install zip unzip jq -y
- name: Make
shell: bash
run: |
get_prop() { sed -n "s|^$1=||p" module.prop; }
ID="$(get_prop id)"
VERSION="$(get_prop version)"
VERSIONCODE="$(get_prop versionCode)"
zip -r "$ID-v$VERSION-($VERSIONCODE).zip" * -x ".git" -x "README.md"
- name: Update
shell: bash
run: |
get_prop() { sed -n "s|^$1=||p" module.prop; }
ID="$(get_prop id)"
VERSION="$(get_prop version)"
VERSIONCODE="$(get_prop versionCode)"
ZIPURL="https://github.com/LittleDipshit/AntiAMTS-Magisk/releases/download/v$VERSION/$ID-v$VERSION-($VERSIONCODE).zip"
cat update.json | jq --arg vn $VERSION --arg vc $VERSIONCODE --arg zu $ZIPURL '. + {version: $vn, versionCode: $vc, zipUrl: $zu}' > update.json
- name: Publish
uses: softprops/action-gh-release@v1
with:
files: *-v*-(*).zip

Check failure on line 41 in .github/workflows/module.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/module.yml

Invalid workflow file

You have an error in your yaml syntax on line 41
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Setup Git
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
- name: Commit Changes
run: |
git add .
git commit -m "Update update.json" || true
git push || true