From ab25fb933e8b6b2a7e5d6b615d05aae6478e6216 Mon Sep 17 00:00:00 2001 From: Alexander Harding Date: Wed, 13 Nov 2024 19:39:51 -0600 Subject: [PATCH 1/5] ci: beta.vger.app support (#1715) --- .github/workflows/build_release.yml | 32 +++++++++++++++++-- README.md | 8 +++++ .../pages/settings/about/AppDetails.tsx | 3 +- 3 files changed, 40 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_release.yml b/.github/workflows/build_release.yml index b24a9bbd47..fa41b647f7 100644 --- a/.github/workflows/build_release.yml +++ b/.github/workflows/build_release.yml @@ -15,14 +15,33 @@ on: env: APP_GIT_REF: ${{ inputs.is_main_build && github.sha || github.ref_name }} - APP_BUILD: ${{ inputs.app_build }} concurrency: group: release jobs: + # get app build env from git commit message + app_build: + runs-on: ubuntu-latest + env: + COMMIT_MSG: ${{ github.event.head_commit.message }} + steps: + - if: inputs.is_main_build != true + run: | + # get app build in parentheses from commit message + APP_BUILD=$(echo "$COMMIT_MSG" | sed -n 's/.*(\([0-9]*\)).*/\1/p') + # verify app_build is a number + if echo "$APP_BUILD" | grep -qE '^[0-9]+$'; then + echo "app_build=$APP_BUILD" >> $GITHUB_OUTPUT + fi + outputs: + app_build: ${{ inputs.app_build || steps.app_build.outputs.app_build }} + build_web: + needs: app_build runs-on: ubuntu-latest + env: + APP_BUILD: ${{ needs.app_build.outputs.app_build }} steps: - uses: actions/checkout@v4 @@ -45,7 +64,7 @@ jobs: args: --acl public-read --follow-symlinks --delete env: SOURCE_DIR: dist - AWS_S3_BUCKET: ${{ secrets.AWS_S3_BUCKET }} + AWS_S3_BUCKET: ${{ inputs.is_main_build && 'beta.vger.app' || 'vger.app'}} AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} @@ -60,8 +79,11 @@ jobs: path: Voyager-Web-${{ env.APP_GIT_REF }}.zip build_ios: + needs: app_build environment: deploy runs-on: macos-latest + env: + APP_BUILD: ${{ needs.app_build.outputs.app_build }} steps: - uses: actions/checkout@v4 @@ -116,7 +138,10 @@ jobs: path: Voyager-iOS-${{ env.APP_GIT_REF }}.ipa build_android: + needs: app_build runs-on: ubuntu-latest + env: + APP_BUILD: ${{ needs.app_build.outputs.app_build }} steps: - uses: actions/checkout@v4 @@ -164,8 +189,11 @@ jobs: path: Voyager-Android-${{ env.APP_GIT_REF }}.apk build_android_play: + needs: app_build environment: deploy runs-on: ubuntu-latest + env: + APP_BUILD: ${{ needs.app_build.outputs.app_build }} steps: - uses: actions/checkout@v4 diff --git a/README.md b/README.md index 58633cd963..b812cb5d8b 100644 --- a/README.md +++ b/README.md @@ -99,6 +99,14 @@ However, if you prefer using the Progressive Web App, there are a number of folk > **Note**: Community deployments are **NOT** maintained by the Voyager team. They may not be synced with Voyager's source code. Please do your own research about the host servers before using them. +### Beta Testing + +Voyager maintains a beta track continuously deployed from every commit to [`refs/heads/main`](https://github.com/aeharding/voyager/commits/main)). **The beta build may break at any time.** + +- [iOS – Testflight](https://testflight.apple.com/join/nWLw1MBM) +- [Android – Google Play Open Testing](https://play.google.com/apps/testing/app.vger.voyager) +- [Web App – beta.vger.app](https://beta.vger.app) + ### Self-Host There are two ways you can run Voyager as a PWA in a production environment. The recommended method is using **docker**. We also support a **traditional** deployment method without docker. Read below to see how to get each method set up. diff --git a/src/routes/pages/settings/about/AppDetails.tsx b/src/routes/pages/settings/about/AppDetails.tsx index a3c1bb3b57..149d1d2b58 100644 --- a/src/routes/pages/settings/about/AppDetails.tsx +++ b/src/routes/pages/settings/about/AppDetails.tsx @@ -25,7 +25,8 @@ const AppContainer = styled.div` const buildInfo = (() => { if (import.meta.env.DEV) return Development; - if (APP_BUILD) + // If the app version is different from the git ref (tag), it's a pre-release + if (APP_GIT_REF !== APP_VERSION) return ( Beta Track — [{APP_BUILD}] {APP_GIT_REF.slice(0, 7)} From ac38687bf7d7b2a4655681e0afab11b8bea43de6 Mon Sep 17 00:00:00 2001 From: Alexander Harding Date: Thu, 14 Nov 2024 02:41:26 -0600 Subject: [PATCH 2/5] fix: workaround for user login breaking app routing in certain cases (#1718) --- src/routes/TabbedRoutes.tsx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/routes/TabbedRoutes.tsx b/src/routes/TabbedRoutes.tsx index ba23eeb7d4..d69b8844ba 100644 --- a/src/routes/TabbedRoutes.tsx +++ b/src/routes/TabbedRoutes.tsx @@ -85,7 +85,13 @@ function InnerTabbedRoutes({ if (pathnameSections <= 1) return; function push() { - router.push(`/${tabRef?.current || "posts"}`, "none", "push"); + // TODO requestAnimationFrame workaround added for regression caused in react 19 upgrades, + // broke right after eda26916b56ca0593f4711516a3ef3048f75fbb6. needs investigation + // repro: be completely logged out. restart app. login. go to a post, go back, + // repeat navigations, see issue + requestAnimationFrame(() => { + router.push(`/${tabRef?.current || "posts"}`, "none", "push"); + }); } // have to wait for the ActorRedirect to do its thing, so it doesn't get clobbered From d3a71d7a47d955aaa5f35c12b7cb259429d8e6c5 Mon Sep 17 00:00:00 2001 From: Alexander Harding Date: Thu, 14 Nov 2024 02:48:05 -0600 Subject: [PATCH 3/5] fix: ios dark mode icons not available (#1720) --- .github/workflows/build_release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build_release.yml b/.github/workflows/build_release.yml index fa41b647f7..39a438a20a 100644 --- a/.github/workflows/build_release.yml +++ b/.github/workflows/build_release.yml @@ -81,7 +81,7 @@ jobs: build_ios: needs: app_build environment: deploy - runs-on: macos-latest + runs-on: macos-15 env: APP_BUILD: ${{ needs.app_build.outputs.app_build }} steps: @@ -97,7 +97,7 @@ jobs: with: node-version: 22 - - uses: maxim-lobanov/setup-xcode@v1 + - uses: maxim-lobanov/setup-xcode@60606e260d2fc5762a71e64e74b2174e8ea3c8bd # v1.6.0 with: xcode-version: latest-stable From 7ec8c2cbcb4be1dd410b2ea86a0b3b13ff205a02 Mon Sep 17 00:00:00 2001 From: Alexander Harding Date: Thu, 14 Nov 2024 02:55:05 -0600 Subject: [PATCH 4/5] ci: always upload s3 artifacts on release (#1721) --- .github/workflows/build_release.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build_release.yml b/.github/workflows/build_release.yml index 39a438a20a..cc58ba90a7 100644 --- a/.github/workflows/build_release.yml +++ b/.github/workflows/build_release.yml @@ -58,7 +58,6 @@ jobs: run: pnpm build - name: Upload dist bundle to S3 - if: inputs.is_main_build != true uses: jakejarvis/s3-sync-action@v0.5.1 with: args: --acl public-read --follow-symlinks --delete From 39e1a35d9321dfea9a468a62478f6f568b90966a Mon Sep 17 00:00:00 2001 From: Alexander Harding Date: Thu, 14 Nov 2024 03:03:30 -0600 Subject: [PATCH 5/5] release: bump version to 2.19.2 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index e4dd30e2f9..8ec7a3486c 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "voyager", "description": "A progressive webapp Lemmy client", "private": true, - "version": "2.19.1", + "version": "2.19.2", "type": "module", "packageManager": "pnpm@9.12.2+sha512.22721b3a11f81661ae1ec68ce1a7b879425a1ca5b991c975b074ac220b187ce56c708fe5db69f4c962c989452eee76c82877f4ee80f474cebd61ee13461b6228", "scripts": {