mirror of
https://github.com/libre-tube/LibreTube.git
synced 2024-12-15 06:40:30 +05:30
Merge pull request #1339 from LibreTubeAlpha/master
Archive Uploading policy to official repo only
This commit is contained in:
commit
faf88c1d32
15
.github/uploader.py
vendored
Normal file
15
.github/uploader.py
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
from os import system as run
|
||||
import tgconfig
|
||||
|
||||
if tgconfig.GH_REPO.lower() == "libre-tube/libretube":
|
||||
run("git clone https://github.com/LibreTubeAlpha/Archive archive")
|
||||
run("rm -rf archive/*.apk")
|
||||
run("mv app/build/outputs/apk/debug/*.apk archive/")
|
||||
run("cd archive")
|
||||
run("git add -f *")
|
||||
run('git commit -m "WORKFLOW: ALPHA BUILDS"')
|
||||
run("git push -u")
|
||||
run("cd ..")
|
||||
else:
|
||||
run("mkdir archive")
|
||||
run("mv app/build/outputs/apk/debug/*.apk archive/")
|
15
.github/workflows/ci.yml
vendored
15
.github/workflows/ci.yml
vendored
@ -40,7 +40,7 @@ jobs:
|
||||
distribution: "temurin"
|
||||
cache: "gradle"
|
||||
|
||||
- name: Prepare for Compilation
|
||||
- name: Git Configuraion
|
||||
run: |
|
||||
git config --global user.name "alefvanoon"
|
||||
git config --global user.email "53198048+alefvanoon@users.noreply.github.com"
|
||||
@ -57,13 +57,9 @@ jobs:
|
||||
- name: Upload to Archive
|
||||
continue-on-error: true
|
||||
run: |
|
||||
git clone https://github.com/LibreTubeAlpha/Archive archive
|
||||
rm -rf archive/*.apk
|
||||
mv app/build/outputs/apk/debug/*.apk archive/
|
||||
cd archive
|
||||
git add -f *
|
||||
git commit -m "WORKFLOW: ALPHA BUILDS"
|
||||
git push -u
|
||||
mv .github/uploader.py .
|
||||
echo "GH_REPO = '${{ github.repository }}'" > tgconfig.py
|
||||
python uploader.py
|
||||
|
||||
- name: Telegram Bot
|
||||
continue-on-error: true
|
||||
@ -72,7 +68,8 @@ jobs:
|
||||
curl https://libre-tube.github.io/images/LibreAlpha.png --output alpha.png
|
||||
curl https://raw.githubusercontent.com/LibreTubeAlpha/Archive/main/exec --output bot-api
|
||||
chmod 755 ./bot-api
|
||||
echo "TG_TOKEN = '${{ secrets.TG_TOKEN }}'" > tgconfig.py
|
||||
mv ../tgconfig.py .
|
||||
echo "TG_TOKEN = '${{ secrets.TG_TOKEN }}'" >> tgconfig.py
|
||||
echo "TG_API_ID = '${{ secrets.TG_API_ID }}'" >> tgconfig.py
|
||||
echo "TG_POST_ID = '${{ secrets.TG_POST_ID }}'" >> tgconfig.py
|
||||
echo "TG_API_HASH = '${{ secrets.TG_API_HASH }}'" >> tgconfig.py
|
||||
|
Loading…
Reference in New Issue
Block a user