Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate Rift and Quest upload #520

Merged
merged 1 commit into from
Sep 7, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 39 additions & 12 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -737,8 +737,8 @@ jobs:
CHANNEL: android-quest-${{ env.ITCH_SUBCHANNEL_NAME }}
PACKAGE: releases/OpenBrush_Quest_${{ needs.configuration.outputs.version }}.apk

publish_oculus:
name: Publish Oculus Release
publish_oculus_quest:
name: Publish Oculus Quest Release
needs: [configuration, build]
runs-on: macos-latest # the ovr-platform-util tool is only available for Mac and Windows
if: |
Expand All @@ -747,11 +747,6 @@ jobs:
(github.ref == 'refs/heads/main' || contains(github.ref, 'refs/tags/v'))

steps:
- name: Download Build Artifacts (Windows Rift)
uses: actions/download-artifact@v3
with:
name: Windows Rift
path: build_windows_rift
- name: Download Build Artifacts (Oculus Quest)
uses: actions/download-artifact@v3
with:
Expand All @@ -762,27 +757,59 @@ jobs:
VERSION: ${{ needs.configuration.outputs.version }}
PRERELEASE: ${{ needs.configuration.outputs.prerelease }}
RAW_CHANGELOG: ${{ needs.configuration.outputs.rawchangelog }}
OCULUS_RIFT_APP_ID: ${{ secrets.OCULUS_RIFT_APP_ID }}
OCULUS_RIFT_APP_SECRET: ${{ secrets.OCULUS_RIFT_APP_SECRET }}
OCULUS_QUEST_APP_ID: ${{ secrets.OCULUS_QUEST_APP_ID }}
OCULUS_QUEST_APP_SECRET: ${{ secrets.OCULUS_QUEST_APP_SECRET }}
run: |
mkdir releases
mv build_oculus_quest/*/com.Icosa.OpenBrush*apk releases/OpenBrush_Quest_$VERSION.apk
mv build_oculus_quest/*/com.Icosa.OpenBrush*.symbols.zip releases/symbols.zip
mv build_windows_rift/StandaloneWindows64-Oculus/ releases/OpenBrush_Rift_$VERSION/
cd releases
unzip symbols.zip
zip -r OpenBrush_Rift_$VERSION.zip OpenBrush_Rift_$VERSION/
curl -L 'https://www.oculus.com/download_app/?id=1462426033810370' -o ovr-platform-util
chmod 755 ovr-platform-util

if [ "$PRERELEASE" == "false" ]
then
./ovr-platform-util upload-quest-build --app-id ${OCULUS_QUEST_APP_ID} --app-secret ${OCULUS_QUEST_APP_SECRET} --apk OpenBrush_Quest_$VERSION.apk --channel LIVE --debug_symbols_dir ./arm64-v8a/ --debug-symbols-pattern '*.so'
./ovr-platform-util upload-rift-build --app-id ${OCULUS_RIFT_APP_ID} --app-secret ${OCULUS_RIFT_APP_SECRET} --build-dir OpenBrush_Rift_$VERSION --launch-file OpenBrush.exe --channel LIVE --version $VERSION --firewall_exceptions true --redistributables 822786567843179,1675031999409058,2657209094360789
else
CHANGELOG="${RAW_CHANGELOG}"
./ovr-platform-util upload-quest-build --app-id ${OCULUS_QUEST_APP_ID} --app-secret ${OCULUS_QUEST_APP_SECRET} --apk OpenBrush_Quest_$VERSION.apk --channel Beta --debug_symbols_dir ./arm64-v8a/ --debug-symbols-pattern '*.so' --notes "${CHANGELOG}"
fi

publish_oculus_rift:
name: Publish Oculus Rift Release
needs: [configuration, build]
runs-on: macos-latest # the ovr-platform-util tool is only available for Mac and Windows
if: |
github.event_name == 'push' &&
github.repository == 'icosa-foundation/open-brush' &&
(github.ref == 'refs/heads/main' || contains(github.ref, 'refs/tags/v'))

steps:
- name: Download Build Artifacts (Windows Rift)
uses: actions/download-artifact@v3
with:
name: Windows Rift
path: build_windows_rift
- name: Publish Oculus Builds
env:
VERSION: ${{ needs.configuration.outputs.version }}
PRERELEASE: ${{ needs.configuration.outputs.prerelease }}
RAW_CHANGELOG: ${{ needs.configuration.outputs.rawchangelog }}
OCULUS_RIFT_APP_ID: ${{ secrets.OCULUS_RIFT_APP_ID }}
OCULUS_RIFT_APP_SECRET: ${{ secrets.OCULUS_RIFT_APP_SECRET }}
run: |
mkdir releases
mv build_windows_rift/StandaloneWindows64-Oculus/ releases/OpenBrush_Rift_$VERSION/
cd releases
zip -r OpenBrush_Rift_$VERSION.zip OpenBrush_Rift_$VERSION/
curl -L 'https://www.oculus.com/download_app/?id=1462426033810370' -o ovr-platform-util
chmod 755 ovr-platform-util

if [ "$PRERELEASE" == "false" ]
then
./ovr-platform-util upload-rift-build --app-id ${OCULUS_RIFT_APP_ID} --app-secret ${OCULUS_RIFT_APP_SECRET} --build-dir OpenBrush_Rift_$VERSION --launch-file OpenBrush.exe --channel LIVE --version $VERSION --firewall_exceptions true --redistributables 822786567843179,1675031999409058,2657209094360789
else
CHANGELOG="${RAW_CHANGELOG}"
./ovr-platform-util upload-rift-build --app-id ${OCULUS_RIFT_APP_ID} --app-secret ${OCULUS_RIFT_APP_SECRET} --build-dir OpenBrush_Rift_$VERSION --launch-file OpenBrush.exe --channel BETA --version $VERSION --firewall_exceptions true --redistributables 822786567843179,1675031999409058,2657209094360789 --notes "${CHANGELOG}"
fi
Loading