diff --git a/.github/workflows/reusable-dart-analyze-format-test.yaml b/.github/workflows/reusable-dart-analyze-format-test.yaml index a622eea2..1ca4dc9b 100644 --- a/.github/workflows/reusable-dart-analyze-format-test.yaml +++ b/.github/workflows/reusable-dart-analyze-format-test.yaml @@ -19,6 +19,9 @@ jobs: matrix: sdk_version: [beta, stable] steps: + - name: Install SQLite3 + run: sudo apt-get update && sudo apt-get -y install sqlite3 libsqlite3-dev + - uses: dart-lang/setup-dart@v1.0 with: sdk: ${{ matrix.sdk_version }} diff --git a/packages/brick_offline_first_with_supabase/CHANGELOG.md b/packages/brick_offline_first_with_supabase/CHANGELOG.md index a46c8c92..936ea7e1 100644 --- a/packages/brick_offline_first_with_supabase/CHANGELOG.md +++ b/packages/brick_offline_first_with_supabase/CHANGELOG.md @@ -1,5 +1,9 @@ ## Unreleased +## 1.1.2 + +- Support a custom database path when creating the cache manager (#490) + ## 1.1.1 - Allow a generic type argument for `OfflineFirstWithSupabaseRepository` diff --git a/packages/brick_offline_first_with_supabase/lib/src/offline_first_with_supabase_repository.dart b/packages/brick_offline_first_with_supabase/lib/src/offline_first_with_supabase_repository.dart index 2d390c0b..d004a85c 100644 --- a/packages/brick_offline_first_with_supabase/lib/src/offline_first_with_supabase_repository.dart +++ b/packages/brick_offline_first_with_supabase/lib/src/offline_first_with_supabase_repository.dart @@ -402,6 +402,7 @@ abstract class OfflineFirstWithSupabaseRepository< /// the queue is used to add offline to the repository. static (RestOfflineQueueClient, RestOfflineRequestQueue) clientQueue({ required DatabaseFactory databaseFactory, + String databasePath = 'brick_offline_queue.sqlite', /// These paths will not be stored in the offline queue. /// By default, Supabase Auth and Storage paths are ignored. @@ -436,7 +437,7 @@ abstract class OfflineFirstWithSupabaseRepository< final client = RestOfflineQueueClient( innerClient ?? http.Client(), RestRequestSqliteCacheManager( - 'brick_offline_queue.sqlite', + databasePath, databaseFactory: databaseFactory, processingInterval: processingInterval, serialProcessing: serialProcessing, diff --git a/packages/brick_offline_first_with_supabase/pubspec.yaml b/packages/brick_offline_first_with_supabase/pubspec.yaml index d3d58dbf..8ab938c4 100644 --- a/packages/brick_offline_first_with_supabase/pubspec.yaml +++ b/packages/brick_offline_first_with_supabase/pubspec.yaml @@ -5,7 +5,7 @@ homepage: https://github.com/GetDutchie/brick/tree/main/packages/brick_offline_f issue_tracker: https://github.com/GetDutchie/brick/issues repository: https://github.com/GetDutchie/brick -version: 1.1.1 +version: 1.1.2 environment: sdk: ">=3.0.0 <4.0.0"