Skip to content

Fix https://github.com/geode-sdk/ios-launcher/issues/72, the pain is … #233

Fix https://github.com/geode-sdk/ios-launcher/issues/72, the pain is …

Fix https://github.com/geode-sdk/ios-launcher/issues/72, the pain is … #233

Workflow file for this run

name: Build
on:
push:
pull_request:
workflow_dispatch:
jobs:
build:
name: Build
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Theos
run: |
# uncomment for swift
#sudo apt-get install -y libtinfo6
echo "installing theos"
export THEOS=$(mktemp -d theos.XXXXX)
echo "THEOS=$THEOS" >> $GITHUB_ENV
# set architecture for the download urls below
export ARCH=$(uname -m)
# depth=1 for SPEED
git clone --recursive https://github.com/theos/theos.git $THEOS --depth=1
# uncomment for swift
#curl -sL https://github.com/kabiroberai/swift-toolchain-linux/releases/download/v2.3.0/swift-5.8-ubuntu20.04.tar.xz | tar -xJvf - -C $THEOS/toolchain/
echo "downloading llvm toolchain"
curl -sL https://github.com/L1ghtmann/llvm-project/releases/latest/download/iOSToolchain-$ARCH.tar.xz | tar -xJvf - -C $THEOS/toolchain/
# yoinked from theos install script
if [[ -x $THEOS/toolchain/linux/iphone/bin/clang ]]; then
echo "Successfully installed the toolchain!"
else
echo "Something appears to have gone wrong -- the toolchain is not accessible. Please try again."
exit 7
fi
echo "installing sdk !!"
$THEOS/bin/install-sdk iPhoneOS16.5
- name: Replace Download Link
run: |
sed -i 's|__DOWNLOAD_LINK__|${{ secrets.GD_DOWNLOAD }}|' src/RootViewController.m
sed -i 's|__KEY_PART1__|${{ secrets.KEYONE }}|' src/RootViewController.m
sed -i 's|__KEY_PART2__|${{ secrets.KEYTWO }}|' src/RootViewController.m
- name: Build
run: |
git submodule update --init --recursive
make package FINALPACKAGE=1 STRIP=0
make clean
make package FINALPACKAGE=1 STRIP=0 TROLLSTORE=1
- name: Upload artifact
uses: actions/upload-artifact@main
with:
name: GeodeLauncher
path: packages/*.*
publish:
name: Publish
runs-on: ubuntu-latest
needs: build
if: github.ref == 'refs/heads/main'
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Declare Version Variables
id: ref
run: |
echo "version=$(cat VERSION | xargs)" >> $GITHUB_OUTPUT
echo "hash=$(git rev-parse --short "$GITHUB_SHA")" >> $GITHUB_OUTPUT
- name: Download Artifacts
uses: actions/download-artifact@v4
with:
path: ${{ github.workspace }}/artifacts
- name: Rename files
run: |
mv artifacts/GeodeLauncher/com.geode.launcher_${{ steps.ref.outputs.version }}.ipa artifacts/GeodeLauncher/com.geode.launcher_${{ steps.ref.outputs.hash }}.ipa
mv artifacts/GeodeLauncher/com.geode.launcher_${{ steps.ref.outputs.version }}.tipa artifacts/GeodeLauncher/com.geode.launcher_${{ steps.ref.outputs.hash }}.tipa
- name: Update Development Release
uses: andelf/nightly-release@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
#tag_name: v999999.9.9 # thanks cvolton
tag_name: nightly
name: 'Development Release'
body: Geode iOS development release for commit ${{ github.sha }}. This is meant for developers. Please look below this release for the latest stable release.
files: |
./artifacts/GeodeLauncher/*.ipa
./artifacts/GeodeLauncher/*.tipa