-
Notifications
You must be signed in to change notification settings - Fork 6
RG-T132 Build fix #276
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
RG-T132 Build fix #276
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -193,12 +193,35 @@ jobs: | |
| - name: 📋 Create Google Json File | ||
| if: ${{ matrix.platform == 'android' }} | ||
| run: | | ||
| echo $UNIT_GOOGLE_SERVICES | base64 -d > google-services.json | ||
| printf '%s' "$UNIT_GOOGLE_SERVICES" | base64 -d > google-services.json | ||
|
|
||
| # Keystore is decoded OUTSIDE the project root so it can never be picked up | ||
| # by the EAS build archive or any artifact globs; credentials.json points to | ||
| # it via an absolute path (supported by EAS for local credentials). | ||
| - name: 📋 Create Android Keystore | ||
| if: ${{ matrix.platform == 'android' }} | ||
| run: | | ||
| printf '%s' "$UNIT_ANDROID_KS" | base64 -d > "$RUNNER_TEMP/keystore.jks" | ||
| chmod 600 "$RUNNER_TEMP/keystore.jks" | ||
|
|
||
| - name: 📋 Ensure jq exists | ||
| if: ${{ matrix.platform == 'android' }} | ||
| run: | | ||
| if ! command -v jq >/dev/null 2>&1; then | ||
| echo "Installing jq..." | ||
| sudo apt-get update && sudo apt-get install -y jq | ||
| fi | ||
|
|
||
| - name: 📋 Create Credentials File | ||
| if: ${{ matrix.platform == 'android' }} | ||
| run: | | ||
| printf '%s' "$CREDENTIALS_JSON_BASE64" | base64 -d \ | ||
| | jq --arg ks "$RUNNER_TEMP/keystore.jks" '.android.keystore.keystorePath = $ks' > credentials.json | ||
|
Comment on lines
+217
to
+219
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Android build failure in - name: Ensure jq exists
if: ${{ matrix.platform == 'android' }}
run: |
if ! command -v jq >/dev/null 2>&1; then
sudo apt-get update && sudo apt-get install -y jq
fi
- name: 📋 Create Credentials File
if: ${{ matrix.platform == 'android' }}
run: |
printf '%s' "$CREDENTIALS_JSON_BASE64" | base64 -d \
| jq --arg ks "$RUNNER_TEMP/keystore.jks" '.android.keystore.keystorePath = $ks' > credentials.jsonPrompt for LLMTalk to Kody by mentioning @kody Was this suggestion helpful? React with 👍 or 👎 to help Kody learn from this interaction. |
||
|
|
||
| - name: 📋 Create Google Json File for iOS | ||
| if: ${{ matrix.platform == 'ios' }} | ||
| run: | | ||
| echo $UNIT_IOS_GOOGLE_SERVICES | base64 -d > GoogleService-Info.plist | ||
| printf '%s' "$UNIT_IOS_GOOGLE_SERVICES" | base64 -d > GoogleService-Info.plist | ||
|
|
||
| - name: 📋 Update package.json Versions | ||
| run: | | ||
|
|
@@ -243,16 +266,17 @@ jobs: | |
| eas --version | ||
|
|
||
| - name: 📋 Create iOS Cert | ||
| if: ${{ matrix.platform == 'ios' }} | ||
| run: | | ||
| echo $UNIT_IOS_CERT | base64 -d > AuthKey_HRBP5FNJN6.p8 | ||
| printf '%s' "$UNIT_IOS_CERT" | base64 -d > AuthKey_HRBP5FNJN6.p8 | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
|
|
||
| - name: 📋 Restore gradle.properties | ||
| env: | ||
| GRADLE_PROPERTIES: ${{ secrets.GRADLE_PROPERTIES }} | ||
| shell: bash | ||
| run: | | ||
| mkdir -p ~/.gradle/ | ||
| echo ${GRADLE_PROPERTIES} > ~/.gradle/gradle.properties | ||
| printf '%s\n' "$GRADLE_PROPERTIES" > ~/.gradle/gradle.properties | ||
|
|
||
| - name: 📱 Build Development APK | ||
| if: (matrix.platform == 'android' && (github.event.inputs.buildType == 'all' || github.event_name == 'push' || github.event.inputs.buildType == 'dev')) | ||
|
|
@@ -275,7 +299,7 @@ jobs: | |
| if: (matrix.platform == 'android' && (github.event.inputs.buildType == 'all' || github.event_name == 'push' || github.event.inputs.buildType == 'prod-aab')) | ||
| run: | | ||
| export NODE_OPTIONS="--openssl-legacy-provider --max_old_space_size=4096" | ||
| eas build --platform android --profile production --local --non-interactive --output=./ResgridUnit-prod.aab | ||
| eas build --platform android --profile production-aab --local --non-interactive --output=./ResgridUnit-prod.aab | ||
| env: | ||
| NODE_ENV: production | ||
|
|
||
|
|
@@ -303,6 +327,10 @@ jobs: | |
| env: | ||
| NODE_ENV: production | ||
|
|
||
| - name: 🧹 Remove signing materials | ||
| if: always() | ||
| run: rm -f credentials.json AuthKey_HRBP5FNJN6.p8 "$RUNNER_TEMP/keystore.jks" ~/.gradle/gradle.properties | ||
|
|
||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
| - name: 📦 Upload build artifacts to GitHub | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
|
|
||
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.
External command failure handling is missing in .github/workflows/react-native-cicd.yml for
apt-get updateandapt-get install -y jq, so package-manager errors can fail without contextual diagnostics. Add explicit handling around these external calls so the workflow emits a clear failure message and exits deterministically.Kody rule violation: Add try-catch blocks for external calls
Prompt for LLM
Talk to Kody by mentioning @kody
Was this suggestion helpful? React with 👍 or 👎 to help Kody learn from this interaction.