Repository navigation
Silo plus #1122
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
Closed
Closed
Silo plus #1122
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
eaa0891
Silo Plus: open the server's plugin pages (Apps) in the phone and TV …
claude c58c60a
Silo Plus workflow: test-signed build when the signing secrets are mi…
claude 5f9c5a5
Name the app Silo+
claude 24df9aa
Add a + badge to the Silo+ launcher icons and TV banner
claude 8f6355b
Silo+: Live TV tab in the TV top bar and phone profile menu
claude 700af31
Silo+: native Live TV player for the Xtream IPTV plugin
claude 82c5a6e
Silo+ player: rename setVolume to avoid a JVM signature clash with th…
claude 3eebbf8
Silo+: + on every in-app logo and the splash; no lingering play button
claude 2f638a5
Silo+ player: Media3 controls only while the player controls are open
claude 6ecf7c8
Silo+ Live TV: TV guide with mini video, auto frame rate, tracks, inf…
claude 5bb14f4
Silo+ Live TV: one player, clean picture-in-picture, no leftover streams
claude 38f2ea9
Silo+ Live TV: optional on-screen clock (top/bottom, left/right)
claude 14f0005
Silo+: Live TV recently watched row at the top of Home (phone and TV)
claude e3e282f
Silo+ phone: themes and custom CSS (Settings → Silo+ → Themes & CSS)
claude 77abf45
feat(plus): in-app updates and weekly sync with Silo
claude d398fab
Sync with Silo (9a443da1)
claude bfbd2c6
feat(plus): full TV guide grid with catch-up
claude 8a13433
feat(plus): Sports on TV panel and score alerts in Live TV
claude 6aa7f0a
feat(plus): debrid files in the native player and a Live TV home-scre…
claude a957297
fix(plus): guard the score alert before the UI exists
claude 6aeacb6
feat(plus): TV artwork for live channels, catch-up badges and picker,…
claude File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,109 @@ | ||
| name: Sync Silo+ with Silo | ||
|
|
||
| # Every Monday (or from the Actions tab), merge Silo's latest Android code | ||
| # into the silo-plus branch so Silo+ keeps every upstream fix, then publish | ||
| # a new Silo+ release (next patch version), which the apps offer as an | ||
| # in-app update. | ||
| # | ||
| # If the merge conflicts with Silo+'s own changes, nothing is pushed: the | ||
| # run fails and lists the files, so the conflict can be fixed by hand. | ||
| # | ||
| # Optional: a SYNC_TOKEN secret (a personal access token with "repo" and | ||
| # "workflow" scopes). Without it the job uses the built-in token, which | ||
| # GitHub doesn't allow to push changes to workflow files: a Silo update that | ||
| # touches .github/workflows then fails with a message saying so. | ||
|
|
||
| on: | ||
| schedule: | ||
| - cron: "17 4 * * 1" | ||
| workflow_dispatch: | ||
| inputs: | ||
| release: | ||
| description: "Publish a release after syncing (true/false)" | ||
| required: false | ||
| default: "true" | ||
|
|
||
| permissions: | ||
| contents: write | ||
| actions: write | ||
| issues: write | ||
|
|
||
| concurrency: | ||
| group: silo-plus-sync | ||
| cancel-in-progress: false | ||
|
|
||
| jobs: | ||
| sync: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| ref: silo-plus | ||
| fetch-depth: 0 | ||
| token: ${{ secrets.SYNC_TOKEN || github.token }} | ||
|
|
||
| - name: Merge Silo's latest code | ||
| id: merge | ||
| run: | | ||
| git config user.name "Silo+ sync" | ||
| git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | ||
| git remote add upstream https://github.com/Silo-Server/silo-android.git | ||
| git fetch --no-tags upstream main | ||
| before=$(git rev-parse HEAD) | ||
| upstream=$(git rev-parse --short upstream/main) | ||
| if git merge-base --is-ancestor upstream/main HEAD; then | ||
| echo "Silo+ already has Silo $upstream." | ||
| echo "changed=false" >> "$GITHUB_OUTPUT" | ||
| exit 0 | ||
| fi | ||
| if git merge --no-edit -m "Sync with Silo ($upstream)" upstream/main; then | ||
| echo "changed=true" >> "$GITHUB_OUTPUT" | ||
| { | ||
| echo "### Merged Silo $upstream into silo-plus" | ||
| echo | ||
| git log --oneline "$before..upstream/main" | head -50 | sed 's/^/- /' | ||
| } >> "$GITHUB_STEP_SUMMARY" | ||
| else | ||
| files=$(git diff --name-only --diff-filter=U) | ||
| git merge --abort | ||
| { | ||
| echo "### Silo $upstream conflicts with Silo+" | ||
| echo | ||
| echo "These files changed in both. Merge them by hand on the silo-plus branch:" | ||
| echo | ||
| echo "$files" | sed 's/^/- `/; s/$/`/' | ||
| } >> "$GITHUB_STEP_SUMMARY" | ||
| echo "::error::Silo's latest code conflicts with Silo+ in: $(echo $files | tr '\n' ' ')" | ||
| gh issue create --title "Silo+ sync: conflict with Silo $upstream" \ | ||
| --body "$(printf "The weekly sync couldn't merge Silo's latest code. Files changed in both:\n\n%s\n" "$files")" 2>/dev/null || true | ||
| exit 1 | ||
| fi | ||
| env: | ||
| GH_TOKEN: ${{ github.token }} | ||
|
|
||
| - name: Push | ||
| if: steps.merge.outputs.changed == 'true' | ||
| run: | | ||
| if ! git push origin HEAD:silo-plus 2>push.log; then | ||
| cat push.log | ||
| if grep -qi "workflow" push.log; then | ||
| echo "::error::Silo changed its GitHub workflow files, which the built-in token can't push. Add a SYNC_TOKEN secret (personal access token with repo and workflow scopes) and run this again." | ||
| fi | ||
| exit 1 | ||
| fi | ||
| # Keep the fork's main the same as Silo's. | ||
| git push origin upstream/main:refs/heads/main 2>/dev/null || true | ||
| - name: Publish the next Silo+ release | ||
| if: steps.merge.outputs.changed == 'true' && (github.event_name == 'schedule' || inputs.release != 'false') | ||
| env: | ||
| GH_TOKEN: ${{ github.token }} | ||
| run: | | ||
| latest=$(git tag --list 'plus-v*' --sort=-v:refname | head -1) | ||
| latest=${latest#plus-v} | ||
| [ -z "$latest" ] && latest=1.0.0 | ||
| IFS=. read -r major minor patch <<< "$latest" | ||
| next="$major.$minor.$((patch + 1))" | ||
| echo "Publishing Silo+ $next" | ||
| gh workflow run silo-plus.yml --ref silo-plus -f release="$next" | ||
| echo "Started the Silo+ $next build." >> "$GITHUB_STEP_SUMMARY" | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,114 @@ | ||
| name: Silo Plus APKs | ||
|
|
||
| # Builds the Silo Plus phone and TV APKs (Silo with an Apps section for the | ||
| # server's plugin pages, app ID org.siloserver.silo.plus) from the silo-plus | ||
| # branch. Run it from the Actions tab with a version to publish a GitHub | ||
| # release; pushes to silo-plus just build. | ||
| # | ||
| # Signing: add these repository secrets once (Settings → Secrets and variables | ||
| # → Actions). Every build must use the same key, or Android refuses to install | ||
| # an update over the previous one. | ||
| # PLUS_KEYSTORE_B64 base64 of the .jks file | ||
| # PLUS_KEYSTORE_PASSWORD keystore password | ||
| # PLUS_KEY_ALIAS key alias | ||
| # PLUS_KEY_PASSWORD key password (optional, defaults to the keystore password) | ||
|
|
||
| on: | ||
| push: | ||
| branches: [silo-plus] | ||
| workflow_dispatch: | ||
| inputs: | ||
| release: | ||
| description: "Publish as a GitHub release with this version, e.g. 1.0.0 (empty: just build)" | ||
| required: false | ||
| default: "" | ||
|
|
||
| permissions: | ||
| contents: write | ||
|
|
||
| concurrency: | ||
| group: silo-plus-${{ github.ref }} | ||
| cancel-in-progress: true | ||
|
|
||
| jobs: | ||
| apks: | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 90 | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - uses: actions/setup-java@v4 | ||
| with: | ||
| distribution: temurin | ||
| java-version: "21" | ||
|
|
||
| - uses: gradle/actions/setup-gradle@v4 | ||
|
|
||
| - name: Signing key | ||
| env: | ||
| PLUS_KEYSTORE_B64: ${{ secrets.PLUS_KEYSTORE_B64 }} | ||
| PLUS_KEYSTORE_PASSWORD: ${{ secrets.PLUS_KEYSTORE_PASSWORD }} | ||
| PLUS_KEY_ALIAS: ${{ secrets.PLUS_KEY_ALIAS }} | ||
| PLUS_KEY_PASSWORD: ${{ secrets.PLUS_KEY_PASSWORD }} | ||
| run: | | ||
| if [[ -z "$PLUS_KEYSTORE_B64" || -z "$PLUS_KEYSTORE_PASSWORD" || -z "$PLUS_KEY_ALIAS" ]]; then | ||
| # Still build, so code problems show up, but with a throwaway key: | ||
| # these APKs can't update a properly signed install and are never published. | ||
| echo "::warning::Signing secrets are missing; building a test-signed copy that won't be published." | ||
| echo "ALLOW_DEBUG_RELEASE_SIGNING=true" >> "$GITHUB_ENV" | ||
| echo "TEST_SIGNED=1" >> "$GITHUB_ENV" | ||
| exit 0 | ||
| fi | ||
| printf '%s' "$PLUS_KEYSTORE_B64" | base64 -d > "$RUNNER_TEMP/plus.jks" | ||
| { | ||
| echo "SILO_RELEASE_KEYSTORE=$RUNNER_TEMP/plus.jks" | ||
| echo "SILO_RELEASE_KEYSTORE_PASSWORD=$PLUS_KEYSTORE_PASSWORD" | ||
| echo "SILO_RELEASE_KEY_ALIAS=$PLUS_KEY_ALIAS" | ||
| echo "SILO_RELEASE_KEY_PASSWORD=$PLUS_KEY_PASSWORD" | ||
| } >> "$GITHUB_ENV" | ||
| - name: Version | ||
| run: | | ||
| VERSION="${{ inputs.release }}" | ||
| VERSION="${VERSION#v}" | ||
| if [[ -z "$VERSION" ]]; then VERSION="1.0.0"; fi | ||
| # Rises with every run, so each build installs over the last one. | ||
| echo "VERSION=$VERSION" >> "$GITHUB_ENV" | ||
| echo "VERSION_CODE=$((1000 + GITHUB_RUN_NUMBER))" >> "$GITHUB_ENV" | ||
| echo "BUILD=$(( GITHUB_RUN_NUMBER % 1000 ))" >> "$GITHUB_ENV" | ||
| - name: Build APKs | ||
| run: | | ||
| ./gradlew \ | ||
| -Dorg.gradle.jvmargs="-Xmx4g -Dfile.encoding=UTF-8" \ | ||
| :androidApp:assembleRelease :androidTvApp:assembleRelease \ | ||
| "-PsiloVersionName=${VERSION}" \ | ||
| "-PsiloBuildNumber=${BUILD}" \ | ||
| "-PsiloVersionCode=${VERSION_CODE}" \ | ||
| -PsiloReleaseChannel=sideload \ | ||
| --max-workers=2 | ||
| - name: Collect APKs | ||
| run: | | ||
| mkdir apks | ||
| cp androidApp/build/outputs/apk/release/androidApp-universal-release.apk "apks/silo-plus-phone-${VERSION}.apk" | ||
| cp androidTvApp/build/outputs/apk/release/androidTvApp-universal-release.apk "apks/silo-plus-tv-${VERSION}.apk" | ||
| ls -l apks | ||
| "$ANDROID_HOME"/build-tools/*/apksigner verify --print-certs apks/silo-plus-tv-${VERSION}.apk | grep -i "SHA-256" | head -1 || true | ||
| - uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: ${{ env.TEST_SIGNED == '1' && 'silo-plus-apks-TEST-SIGNED' || 'silo-plus-apks' }} | ||
| path: apks/*.apk | ||
|
|
||
| - name: Publish release | ||
| if: github.event_name == 'workflow_dispatch' && inputs.release != '' && env.TEST_SIGNED != '1' | ||
| uses: softprops/action-gh-release@v2 | ||
| with: | ||
| tag_name: plus-v${{ env.VERSION }} | ||
| name: Silo+ ${{ env.VERSION }} | ||
| target_commitish: ${{ github.sha }} | ||
| body: | | ||
| Silo with an **Apps** section (profile menu) that opens your server's plugin pages, such as Xtream IPTV, inside the app. | ||
| Installs next to the official Silo app. Phone/tablet: `silo-plus-phone-${{ env.VERSION }}.apk`. Android TV / Google TV / Fire TV: `silo-plus-tv-${{ env.VERSION }}.apk`. | ||
| files: apks/*.apk |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A failed release cannot be retried after the sync branch is pushed
A dispatch failure or test-signed build can leave a sync permanently unreleased because
steps.merge.outputs.changedis false on subsequent runs. Track publication independently of merge state so release dispatch can be retried after a successful push.Prompt for LLM
Talk to Kody by mentioning @kody
Was this suggestion helpful? React with 👍 or 👎 to help Kody learn from this interaction.