diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 0000000..d673298 --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,98 @@ +name: CI +on: push + +jobs: + analyze: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Set up Flutter + uses: subosito/flutter-action@v2 + - name: Get dependencies + run: | + flutter pub get + flutter analyze + dart format --set-exit-if-changed . + flutter test + build-android: + needs: analyze + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Setup Java + uses: actions/setup-java@v2 + with: + distribution: 'temurin' + java-version: '21' + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + cache: true + - name: Build Android appbundle + run: flutter build appbundle --debug + build-ios: + needs: analyze + runs-on: macos-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + cache: true + - name: Build ios + run: flutter build ios --debug + build-web: + needs: analyze + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + cache: true + - name: Build web + run: flutter build web --debug + build-linux: + needs: analyze + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Setup Linux prerequisites + run: | + sudo apt-get update -y + sudo apt-get install -y ninja-build libgtk-3-dev + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + cache: true + - name: Build linux + run: flutter build linux --debug + build-windows: + needs: analyze + runs-on: windows-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + cache: true + - name: Build windows + run: flutter build windows --debug + build-macos: + needs: analyze + runs-on: macos-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Set up Flutter + uses: subosito/flutter-action@v2 + with: + cache: true + - name: Build macos + run: flutter build macos --debug \ No newline at end of file diff --git a/.gitignore b/.gitignore index 65d3100..86d295d 100644 --- a/.gitignore +++ b/.gitignore @@ -42,4 +42,4 @@ app.*.map.json /android/app/profile /android/app/release -assets/books/ \ No newline at end of file +assets/books/*.epub \ No newline at end of file diff --git a/assets/books/.gitkeep b/assets/books/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/lib/views/linear_pogress_listener.dart b/lib/views/linear_pogress_listener.dart index ca22958..14cc733 100644 --- a/lib/views/linear_pogress_listener.dart +++ b/lib/views/linear_pogress_listener.dart @@ -4,7 +4,6 @@ class LinearProgressController { LinearProgressController(); void Function(double) onProgress = (double progress) {}; - } class LinearProgressListener extends StatefulWidget { @@ -15,7 +14,6 @@ class LinearProgressListener extends StatefulWidget { final LinearProgressController controller; - @override State createState() => _LinearProgressListenerState(); } diff --git a/test/widget_test.dart b/test/widget_test.dart index 34f0a19..c017862 100644 --- a/test/widget_test.dart +++ b/test/widget_test.dart @@ -9,6 +9,6 @@ import 'package:flutter_test/flutter_test.dart'; void main() { testWidgets('Counter increments smoke test', (WidgetTester tester) async { - // + // }); }