Skip to content

Commit

Permalink
feat: Added Github Actions Step Name & Organized Sequence
Browse files Browse the repository at this point in the history
  • Loading branch information
utpal-barman committed Oct 4, 2024
1 parent d9aeb69 commit 7196992
Showing 1 changed file with 36 additions and 13 deletions.
49 changes: 36 additions & 13 deletions .github/workflows/pull_request_validation.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,42 @@
# This workflow builds, analyses and tests every pull request.
# This workflow builds, analyzes, and tests every pull request.
name: Pull Request Validation
on: pull_request
on:
push:
branches:
- develop
- main
- master

pull_request:

jobs:
analyze-and-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-java@v1
- name: 📚 Git Checkout
uses: actions/checkout@v4

- name: 🐦 Setup Flutter
uses: subosito/flutter-action@v2
with:
java-version: "12.x"
- uses: subosito/flutter-action@v1
with:
channel: "stable"
- run: flutter pub get
- run: flutter pub run build_runner build --delete-conflicting-outputs
- run: flutter build apk --release --flavor production -t lib/main_production.dart
- run: flutter analyze
- run: flutter test
channel: 'stable'
cache: true
cache-key: flutter-:os:-:channel:-:version:-:arch:-:hash:-${{ hashFiles('**/pubspec.lock') }}

- name: 📦 Install Dependencies
run: flutter pub get

- name: 🛠️ Build Runner (Generate Code)
run: flutter pub run build_runner build --delete-conflicting-outputs

- name: 🕵️ Analyze Code
run: flutter analyze lib test

- name: ✨ Check Formatting
run: dart format --line-length 80 --set-exit-if-changed lib test

- name: 🏗️ Build APK (Production Flavor)
run: flutter build apk --release --flavor production -t lib/main_production.dart

- name: 🧪 Run Tests
run: flutter test

0 comments on commit 7196992

Please sign in to comment.