-
Notifications
You must be signed in to change notification settings - Fork 0
66 lines (55 loc) · 2.04 KB
/
blank.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
name: Revanced APKs
on:
schedule:
- cron: '0 */6 * * *'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run Revanced Youtube
run: sh revanced youtube
- name: Run Revanced Youtube Music
run: sh revanced youtube-music
- name: Run Revanced Twitter
run: sh revanced twitter
- name: Check for APK files
id: check_apks
run: |
if ls *.apk 1> /dev/null 2>&1;then
echo "apks_exist=true" >> "$GITHUB_OUTPUT"
echo "RELEASE_TAG=$(date +'%Y-%m-%d')" >> "$GITHUB_OUTPUT"
else
echo "apks_exist=false" >> "$GITHUB_OUTPUT"
fi
- name: Upload binaries to release
if: ${{ steps.check_apks.outputs.apks_exist == 'true' }}
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: revanced-*.apk
tag: ${{ steps.check_apks.outputs.RELEASE_TAG }}
overwrite: true
file_glob: true
body: "New Releases."
- name: Notify For New Release
if: ${{ steps.check_apks.outputs.apks_exist == 'true' }}
env:
NTFY_URL: ${{ secrets.NTFY_URL }}
NTFY_TOPIC: ${{ secrets.NTFY_TOPIC }}
NTFY_TOKEN: ${{ secrets.NTFY_TOKEN }}
RELEASE_TAG: ${{ steps.check_apks.outputs.RELEASE_TAG }}
run: |
for i in *.apk;do
app_url="https://github.com/$GITHUB_REPOSITORY/releases/download/$RELEASE_TAG/$i"
curl -s "$NTFY_URL/$NTFY_TOPIC" -d "$app_url" -H "Authorization: Bearer $NTFY_TOKEN" -H "Title: Download $(printf "%s" "$i" | tr '-' ' ')" -H "Click: $app_url"
done
- name: auwuto commit uwu
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "update: New Version"
repository: .
file_pattern: track
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}