Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(ci): Android merges stop cutting a new Play Store build every time #26596

Mergedjuliusmarmingemerged 1 commit intomain fromrefs/pull/26596/headmerged by juliusmarminge View on GitHub

Showing 1 changed file with 14 additions and 1 deletion.

x
0 of 1 viewed, 1 left
14 additions and 1 deletion.github/workflows/mobile-eas-production.ymlModified
View file
@@ -160,7 +160,20 @@
working-directory: apps/mobile
env:
EXPO_TOKEN: ${{ secrets.EXPO_TOKEN }}
- run: eas env:pull production --non-interactive
+ run: |
+ eas env:pull production --non-interactive
+ # EAS commands skip dotenv, and the Android fingerprint hashes this
+ # file. Without it every merge misses the build's hash and rebuilds.
+ node --input-type=module <<'NODE'
+ import { appendFileSync, readFileSync } from "node:fs";
+ import { parseEnv } from "node:util";
+ const env = parseEnv(readFileSync(".env.local", "utf8"));
+ const googleServicesFile = env.T3CODE_ANDROID_GOOGLE_SERVICES_FILE;
+ if (!googleServicesFile) {
+ throw new Error("T3CODE_ANDROID_GOOGLE_SERVICES_FILE is missing from the production environment");
+ }
+ appendFileSync(process.env.GITHUB_ENV, `T3CODE_ANDROID_GOOGLE_SERVICES_FILE=${googleServicesFile}\n`);
+ NODE
​
- name: Apply manual version override
if: steps.version_app_token.outcome == 'success'