Skip to content

Commit 8b6fdf7

Browse files
committed
Update CI: replace create-file-action and add free disk space to release
- Replace `finnp/create-file-action` with shell command to create `ignoreConfig.dart` in build and apk jobs. - Add `jlumbroso/free-disk-space` step to the release job.
1 parent 1cf3d74 commit 8b6fdf7

File tree

1 file changed

+16
-12
lines changed

1 file changed

+16
-12
lines changed

.github/workflows/ci.yml

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,6 @@ jobs:
1818
name: Build
1919
runs-on: ubuntu-latest
2020

21-
22-
23-
2421
steps:
2522
- name: Free Disk Space
2623
uses: jlumbroso/free-disk-space@main
@@ -32,7 +29,6 @@ jobs:
3229
large-packages: true
3330
docker-images: true
3431
swap-storage: true
35-
3632
- uses: actions/checkout@v2
3733
- uses: actions/setup-java@v2
3834
with:
@@ -41,10 +37,9 @@ jobs:
4137
- uses: subosito/flutter-action@v1
4238
with:
4339
flutter-version: '3.38.4'
44-
- uses: finnp/create-file-action@master
45-
env:
46-
FILE_NAME: lib/common/config/ignoreConfig.dart
47-
FILE_DATA: class NetConfig { static const CLIENT_ID = "${{ secrets.CLIENT_ID }}"; static const CLIENT_SECRET = "${{ secrets.CLIENT_SECRET }}";}
40+
- name: Create config file
41+
run: |
42+
echo 'class NetConfig { static const CLIENT_ID = "${{ secrets.CLIENT_ID }}"; static const CLIENT_SECRET = "${{ secrets.CLIENT_SECRET }}";}' > lib/common/config/ignoreConfig.dart
4843
- run: flutter pub get
4944
- run: flutter build apk --release --target-platform=android-arm64 --no-shrink
5045

@@ -63,10 +58,9 @@ jobs:
6358
- uses: subosito/flutter-action@v1
6459
with:
6560
flutter-version: '3.38.4'
66-
- uses: finnp/create-file-action@master
67-
env:
68-
FILE_NAME: lib/common/config/ignoreConfig.dart
69-
FILE_DATA: class NetConfig { static const CLIENT_ID = "${{ secrets.CLIENT_ID }}"; static const CLIENT_SECRET = "${{ secrets.CLIENT_SECRET }}";}
61+
- name: Create config file
62+
run: |
63+
echo 'class NetConfig { static const CLIENT_ID = "${{ secrets.CLIENT_ID }}"; static const CLIENT_SECRET = "${{ secrets.CLIENT_SECRET }}";}' > lib/common/config/ignoreConfig.dart
7064
- run: flutter pub get
7165
- run: flutter build apk --release --target-platform=android-arm64 --no-shrink
7266
- name: Upload APK
@@ -80,6 +74,16 @@ jobs:
8074
if: startsWith(github.ref, 'refs/tags/')
8175
runs-on: ubuntu-latest
8276
steps:
77+
- name: Free Disk Space
78+
uses: jlumbroso/free-disk-space@main
79+
with:
80+
tool-cache: false
81+
android: false
82+
dotnet: true
83+
haskell: true
84+
large-packages: true
85+
docker-images: true
86+
swap-storage: true
8387
- name: Download APK from build
8488
uses: actions/download-artifact@v4
8589
with:

0 commit comments

Comments
 (0)