Skip to content

Build and Release YTMusicUltimate #8

Build and Release YTMusicUltimate

Build and Release YTMusicUltimate #8

Workflow file for this run

name: Build and Release YTMusicUltimate
on:
workflow_dispatch:
inputs:
ipa_url:
description: "URL to the decrypted IPA file"
default: ""
required: true
type: string
display_name:
description: "App Name (Optional)"
default: "YouTube Music"
required: true
type: string
bundle_id:
description: "BundleID (Optional)"
default: "com.google.ios.youtubemusic"
required: true
type: string
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
name: Build YTMusicUltimate
runs-on: macos-latest
permissions:
contents: write
steps:
- name: Checkout Main
uses: actions/checkout@v4.1.1
with:
path: main
submodules: recursive
- name: Hide sensitive inputs
uses: levibostian/action-hide-sensitive-inputs@v1
- name: Validate IPA URL
run: |
curl -L -r 0-1023 -o sample.part "${{ inputs.ipa_url }}" > /dev/null 2>&1
file_type=$(file --mime-type -b sample.part)
if [[ "$file_type" != "application/x-ios-app" && "$file_type" != "application/zip" ]]; then
echo "::error::Validation failed: The file is not a valid IPA file. Detected type: $file_type."
exit 1
fi
- name: Install Dependencies
run: brew install make ldid
- name: Set PATH environment variable
run: echo "$(brew --prefix make)/libexec/gnubin" >> $GITHUB_PATH
- name: Cache Theos
id: theos
uses: actions/cache@v4.0.1
env:
cache-name: theos_cache_67db2ab
with:
path: theos/
key: ${{ env.cache-name }}
restore-keys: ${{ env.cache-name }}
- name: Setup Theos
if: steps.theos.outputs.cache-hit != 'true'
uses: actions/checkout@v4.1.7
with:
repository: theos/theos
ref: 67db2ab8d950910161730de77c322658ea3e6b44
path: ${{ github.workspace }}/theos
submodules: recursive
- name: Download iOS SDK
if: steps.theos.outputs.cache-hit != 'true'
run: |
git clone --quiet -n --depth=1 --filter=tree:0 https://github.com/theos/sdks/
cd sdks
git sparse-checkout set --no-cone iPhoneOS16.5.sdk
git checkout
mv *.sdk $THEOS/sdks
env:
THEOS: ${{ github.workspace }}/theos
- name: Install cyan
run: pipx install --force https://github.com/asdfzxcvbn/pyzule-rw/archive/main.zip
- name: Download YouTube Music
id: download_youtube_music
run: wget "${{ inputs.ipa_url }}" --no-verbose -O ${{ github.workspace }}/main/ytm.ipa
- name: Build Tweak for Sideloading
id: build_package
run: |
cd ${{ github.workspace }}/main
make clean package SIDELOADING=1
env:
THEOS: ${{ github.workspace }}/theos
- name: Inject tweak into provided IPA
run: |
cd ${{ github.workspace }}/main/packages
tweakName=$(ls)
cd ${{ github.workspace }}/main
cyan -i ytm.ipa -o packages/YTMusicUltimate.ipa -uwsf packages/$tweakName -n "${{ inputs.display_name }}" -b ${{ inputs.bundle_id }}
- name: Create Release
uses: softprops/action-gh-release@v2.0.6
with:
name: YTMusicUltimate-v${{ github.run_number }}
files: main/packages/*.ipa
draft: true
- name: Output Release URL
run: |
echo "::notice::Release available at: https://github.com/${{ github.repository }}/releases"