Skip to content

Commit ef8673a

Browse files
committed
Update build script
1 parent 427c6cd commit ef8673a

File tree

3 files changed

+12
-11
lines changed

3 files changed

+12
-11
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,11 @@ jobs:
3939
shell: bash
4040
run: |
4141
# Create the directory structure first to prevent 'No such file or directory' errors
42-
mkdir -p "${GITHUB_WORKSPACE}/composeApp/src/release/"
42+
mkdir -p "composeApp/src/release/"
4343
44-
# Write the secret into the file
45-
echo "$GOOGLE_SERVICES_JSON" > "composeApp/src/release/google-services.json"
44+
# Decode the secret into the file
45+
echo ${{ secrets.$GOOGLE_SERVICES_BASE_64 }} | openssl base64 -d -A \
46+
-out "composeApp/src/release/google-services.json"
4647
4748
- name: Build App
4849
run: ./gradlew assembleRelease

.github/workflows/publish.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ jobs:
2626
shell: bash
2727
run: |
2828
# Create the directory structure first to prevent 'No such file or directory' errors
29-
mkdir -p "${GITHUB_WORKSPACE}/composeApp/src/release/"
29+
mkdir -p "composeApp/src/release/"
3030
31-
# Write the secret into the file
32-
echo "$GOOGLE_SERVICES_JSON" > \
33-
"${GITHUB_WORKSPACE}/composeApp/src/release/google-services.json"
31+
# Decode the secret into the file
32+
echo ${{ secrets.$GOOGLE_SERVICES_BASE_64 }} | openssl base64 -d -A \
33+
-out "composeApp/src/release/google-services.json"
3434
3535
- name: Build Unsigned AAB
3636
run: |

.github/workflows/release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@ jobs:
4444
shell: bash
4545
run: |
4646
# Create the directory structure first to prevent 'No such file or directory' errors
47-
mkdir -p "${GITHUB_WORKSPACE}/composeApp/src/release/"
47+
mkdir -p "composeApp/src/release/"
4848
49-
# Write the secret into the file
50-
echo "$GOOGLE_SERVICES_JSON" > \
51-
"${GITHUB_WORKSPACE}/composeApp/src/release/google-services.json"
49+
# Decode the secret into the file
50+
echo ${{ secrets.$GOOGLE_SERVICES_BASE_64 }} | openssl base64 -d -A \
51+
-out "composeApp/src/release/google-services.json"
5252
5353
- name: Tag release
5454
run: |

0 commit comments

Comments
 (0)