Skip to content

Commit

Permalink
CI: use same flutter version for all workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
ptisserand committed Dec 29, 2024
1 parent 2cd635d commit 4efda9a
Show file tree
Hide file tree
Showing 7 changed files with 71 additions and 16 deletions.
3 changes: 3 additions & 0 deletions .env.ci
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
FLUTTER_VERSION=3.27.1
STARKNET_RPC=http://localhost:5050
DEVNET_DUMP_PATH=/devnet-dump.json
41 changes: 28 additions & 13 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,15 @@ jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: flutter-actions/setup-flutter@v3
with:
channel: stable
version: 3.24.3
version: ${{ steps.load-env.outputs.flutter_version }}
cache: true
cache-sdk: true
- uses: bluefireteam/melos-action@v3
Expand All @@ -26,11 +30,15 @@ jobs:
test-unit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: flutter-actions/setup-flutter@v3
with:
channel: stable
version: 3.24.3
version: ${{ steps.load-env.outputs.flutter_version }}
cache: true
cache-sdk: true
- uses: bluefireteam/melos-action@v3
Expand All @@ -40,11 +48,15 @@ jobs:
test-integration:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: flutter-actions/setup-flutter@v3
with:
channel: stable
version: 3.24.3
version: ${{ steps.load-env.outputs.flutter_version }}
cache: true
cache-sdk: true
- uses: bluefireteam/melos-action@v3
Expand Down Expand Up @@ -73,8 +85,12 @@ jobs:
check-contracts-changes:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/checkout@v3
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- name: Check for changes
uses: dorny/paths-filter@v3
id: changes
Expand All @@ -84,8 +100,7 @@ jobs:
- 'contracts/v2.6.2/**'
- uses: flutter-actions/setup-flutter@v3
with:
channel: stable
version: 3.24.3
version: ${{ steps.load-env.outputs.flutter_version }}
cache: true
cache-sdk: true
- uses: bluefireteam/melos-action@v3
Expand Down
21 changes: 18 additions & 3 deletions .github/workflows/code_health.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: subosito/flutter-action@v2
with:
channel: "stable"
flutter-version: ${{ steps.load-env.outputs.flutter_version }}
cache: true
- uses: bluefireteam/melos-action@v3
- name: "Run Analyze"
Expand All @@ -33,9 +38,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: subosito/flutter-action@v2
with:
channel: "stable"
flutter-version: ${{ steps.load-env.outputs.flutter_version }}
cache: true
- uses: bluefireteam/melos-action@v3
- name: "Pub Check"
Expand All @@ -47,9 +57,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: subosito/flutter-action@v2
with:
channel: "stable"
flutter-version: ${{ steps.load-env.outputs.flutter_version }}
cache: true
- uses: bluefireteam/melos-action@v3
- name: "flutter pub get"
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/release-prepare.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,14 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: subosito/flutter-action@v2
with:
flutter-version: ${{ steps.load-env.outputs.flutter_version }}
- uses: bluefireteam/melos-action@v3
with:
run-versioning: ${{ inputs.prerelease == false }}
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/release-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,14 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: subosito/flutter-action@v2
with:
flutter-version: ${{ steps.load-env.outputs.flutter_version }}
- uses: bluefireteam/melos-action@v3
with:
publish: true
7 changes: 7 additions & 0 deletions .github/workflows/release-tag.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,14 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Dotenv Action
id: load-env
uses: falti/[email protected]
with:
path: .env.ci
- uses: subosito/flutter-action@v2
with:
flutter-version: ${{ steps.load-env.outputs.flutter_version }}
- uses: bluefireteam/melos-action@v3
with:
tag: true
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ coverage/

.env
.env.*
!.env.ci
!.env.example
!.env.mainnet.example
!.env.devnet.example
Expand Down

0 comments on commit 4efda9a

Please sign in to comment.