Skip to content

Commit

Permalink
Merge pull request #170 from JonasWanke/update-CI
Browse files Browse the repository at this point in the history
  • Loading branch information
JonasWanke authored Oct 15, 2024
2 parents 324887d + 559b330 commit 887945d
Show file tree
Hide file tree
Showing 6 changed files with 89 additions and 70 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,21 @@ on:
push:
branches: [main]
schedule:
- cron: 0 4 * * *
- cron: 0 4 * * 1
workflow_dispatch:

env:
JAVA_VERSION: 12.x
JAVA_VERSION: 17

jobs:
test:
name: Run tests
runs-on: ubuntu-latest
strategy:
matrix:
flutter-channel: [stable, beta]
# TODO(JonasWanke): re-enable beta CI when next stable Flutter version
# including breaking changes to Color are released
flutterChannel: [stable]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
Expand All @@ -27,6 +29,7 @@ jobs:
- uses: subosito/flutter-action@v2
with:
channel: ${{ matrix.flutter-channel }}
- run: flutter --version

- run: flutter pub get

Expand All @@ -37,7 +40,9 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
flutter-channel: [stable, beta]
# TODO(JonasWanke): re-enable beta CI when next stable Flutter version
# including breaking changes to Color are released
flutterChannel: [stable]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
Expand All @@ -47,6 +52,7 @@ jobs:
- uses: subosito/flutter-action@v2
with:
channel: ${{ matrix.flutter-channel }}
- run: flutter --version

- run: flutter pub get

Expand All @@ -57,7 +63,9 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
flutter-channel: [stable, beta]
# TODO(JonasWanke): re-enable beta CI when next stable Flutter version
# including breaking changes to Color are released
flutterChannel: [stable]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
Expand All @@ -67,6 +75,7 @@ jobs:
- uses: subosito/flutter-action@v2
with:
channel: ${{ matrix.flutter-channel }}
- run: flutter --version

- run: flutter pub get
working-directory: example
Expand Down
4 changes: 2 additions & 2 deletions example/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ android {
ndkVersion = flutter.ndkVersion

compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}

defaultConfig {
Expand Down
7 changes: 3 additions & 4 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
// ignore_for_file: avoid_print

import 'dart:async';

import 'package:black_hole_flutter/black_hole_flutter.dart';
import 'package:collection/collection.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:time/time.dart';
Expand Down Expand Up @@ -91,7 +92,7 @@ class _TimetableExampleState extends State<TimetableExample>
(it) =>
it.toTimeOverlay(date: date, widget: BasicEventWidget(it)),
)
.whereNotNull()
.nonNulls
.toList(),
]),
callbacks: TimetableCallbacks(
Expand Down Expand Up @@ -259,5 +260,3 @@ extension on PredefinedVisibleDateRange {
};
}
}

// ignore_for_file: avoid_print, unused_element
Loading

0 comments on commit 887945d

Please sign in to comment.