gowalk-cicd 1.0.53 → 1.0.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- 1.0.53
1
+ 1.0.54
@@ -1 +1 @@
1
- 1.0.53
1
+ 1.0.54
@@ -30,6 +30,15 @@ inputs:
30
30
  (flutter analyze + flutter test, or the Gradle module's unit tests)
31
31
  required: false
32
32
  default: "true"
33
+ dart-defines:
34
+ description: >-
35
+ Compile-time Dart defines for a Flutter app, one `KEY=VALUE` per line
36
+ (or whitespace-separated), passed to `flutter build appbundle` as
37
+ `--dart-define`. The package workflow passes the hosted-flow origin
38
+ (`ONBOARDING_PUBLIC_ORIGIN`) from the repository variable of the same
39
+ name. Ignored for native Gradle apps; empty passes nothing.
40
+ required: false
41
+ default: ""
33
42
  firebase-app-id:
34
43
  description: >-
35
44
  Firebase App ID(s) for the Crashlytics symbol upload — the
@@ -120,6 +129,7 @@ runs:
120
129
  shell: bash
121
130
  env:
122
131
  BUILD_NAME: ${{ inputs.build-name }}
132
+ DART_DEFINES: ${{ inputs.dart-defines }}
123
133
  DART_SYMBOLS_DIR: ${{ runner.temp }}/dart-symbols/android
124
134
  run: |
125
135
  args=(
@@ -132,6 +142,15 @@ runs:
132
142
  if [ -n "$BUILD_NAME" ]; then
133
143
  args+=(--build-name "$BUILD_NAME")
134
144
  fi
145
+ # One --dart-define per KEY=VALUE entry; a token without '=' is a
146
+ # workflow authoring error and fails here rather than compiling a
147
+ # define nobody reads.
148
+ for define in $DART_DEFINES; do
149
+ case "$define" in
150
+ *=*) args+=(--dart-define "$define") ;;
151
+ *) echo "::error::dart-defines entry '$define' is not KEY=VALUE"; exit 1 ;;
152
+ esac
153
+ done
135
154
  flutter "${args[@]}"
136
155
  if ! ls "$DART_SYMBOLS_DIR"/*.symbols >/dev/null 2>&1; then
137
156
  echo "::error::flutter build wrote no Dart symbol files to $DART_SYMBOLS_DIR;" \
@@ -1 +1 @@
1
- 1.0.53
1
+ 1.0.54
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gowalk-cicd",
3
- "version": "1.0.53",
3
+ "version": "1.0.54",
4
4
  "description": "Zero-config GitHub Actions delivery for iOS TestFlight and Android Google Play.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -94,6 +94,8 @@ jobs:
94
94
  - name: Prepare Flutter iOS project
95
95
  if: ${{ steps.flutter.outputs.enabled == 'true' }}
96
96
  shell: bash
97
+ env:
98
+ ONBOARDING_PUBLIC_ORIGIN: ${{ vars.ONBOARDING_PUBLIC_ORIGIN }}
97
99
  run: |
98
100
  flutter pub get
99
101
  # Flutter removed the synthetic `package:flutter_gen`, so apps that use
@@ -115,8 +117,18 @@ jobs:
115
117
  # symbol files land under RUNNER_TEMP (never in the checkout) and are
116
118
  # retained after the archive — without them an obfuscated crash log
117
119
  # cannot be read.
120
+ # The hosted-flow origin the app compiles in: the panel's CURRENT
121
+ # value, from the repository variable it keeps in step with the
122
+ # origin it serves, so a hostname re-minted after a build can never
123
+ # stay compiled in. Unset (an app with no hosted flows, or one that
124
+ # predates the variable) leaves the app's own default alone.
125
+ define_args=()
126
+ if [ -n "${ONBOARDING_PUBLIC_ORIGIN:-}" ]; then
127
+ define_args+=(--dart-define "ONBOARDING_PUBLIC_ORIGIN=${ONBOARDING_PUBLIC_ORIGIN}")
128
+ fi
118
129
  flutter build ios --release --no-codesign --config-only \
119
- --obfuscate --split-debug-info="$RUNNER_TEMP/dart-symbols/ios"
130
+ --obfuscate --split-debug-info="$RUNNER_TEMP/dart-symbols/ios" \
131
+ "${define_args[@]}"
120
132
  - uses: ./.github/actions/swift-app
121
133
  id: ios
122
134
  with:
@@ -376,6 +388,11 @@ jobs:
376
388
  # the Dart symbol files to Crashlytics before the bundle goes to Play;
377
389
  # unset, it warns when the app depends on firebase_crashlytics.
378
390
  firebase-app-id: ${{ vars.FIREBASE_APP_ID }}
391
+ # The hosted-flow origin the app compiles in, from the repository
392
+ # variable the panel keeps in step with the origin it serves — the
393
+ # same define the iOS job passes. Empty leaves the app's default.
394
+ dart-defines: >-
395
+ ${{ vars.ONBOARDING_PUBLIC_ORIGIN != '' && format('ONBOARDING_PUBLIC_ORIGIN={0}', vars.ONBOARDING_PUBLIC_ORIGIN) || '' }}
379
396
  - name: Retain signed Android App Bundle
380
397
  if: ${{ steps.mode.outputs.mode == 'local' }}
381
398
  uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5