#!/bin/bash

# Remove old files with clean names
rm -f /repo/YouTube.apk
rm -f /repo/Reddit.apk
rm -f /repo/SoundCloud.apk
rm -f /repo/Duolingo.apk
rm -f /repo/GoogleNews.apk
rm -f /repo/Instagram.apk
rm -f /repo/Twitter.apk
rm -f /repo/NovaLauncher.apk

# Download and rename files directly into /repo
wget -O /repo/YouTube.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/youtube-revanced-extended.apk
wget -O /repo/Reddit.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/reddit-revanced-extended.apk
wget -O /repo/SoundCloud.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/soundcloud-revanced.apk
wget -O /repo/Duolingo.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/duolingo-revanced.apk
wget -O /repo/GoogleNews.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/googlenews-arm64-v8a-revanced.apk
wget -O /repo/Instagram.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/instagram-arm64-v8a-revanced.apk
wget -O /repo/Twitter.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/twitter-stable-piko.apk
wget -O /repo/NovaLauncher.apk https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root/releases/download/all/nova-launcher-indrastorms.apk