diff --git a/hive/CHANGELOG.md b/hive/CHANGELOG.md index f93b068..e133b64 100644 --- a/hive/CHANGELOG.md +++ b/hive/CHANGELOG.md @@ -1,3 +1,7 @@ +## 2.8.0+2 + +- Adds workaround for transitive Hive dependencies to README + ## 2.8.0+1 - Adds tutorial link to README diff --git a/hive/README.md b/hive/README.md index 11d8722..6f2316e 100644 --- a/hive/README.md +++ b/hive/README.md @@ -90,6 +90,23 @@ import 'package:hive_ce/hive.dart'; import 'package:hive_ce_flutter/hive_flutter.dart'; ``` +## Workaround for transitive Hive dependencies + +If you are using a package that depends on Hive v2, you can use the following workaround to force it to use Hive CE: + +```yaml +dependencies: + # Depend on hive_ce to prevent resolving breaking versions + hive_ce: latest + +dependency_overrides: + hive: + git: + url: https://github.com/IO-Design-Team/hive_ce + ref: f8172d4b88b195eea1b1d07e3397332dc77a91ae + path: overrides/hive +``` + ## Usage You can use Hive just like a map. It is not necessary to await `Futures`. diff --git a/hive/pubspec.yaml b/hive/pubspec.yaml index c15d30b..41fa6cf 100644 --- a/hive/pubspec.yaml +++ b/hive/pubspec.yaml @@ -1,6 +1,6 @@ name: hive_ce description: Hive Community Edition - A spiritual continuation of Hive v2 -version: 2.8.0+1 +version: 2.8.0+2 homepage: https://github.com/IO-Design-Team/hive_ce/tree/main/hive documentation: https://docs.hivedb.dev/ diff --git a/overrides/hive/example/pubspec.yaml b/overrides/hive/example/pubspec.yaml index 01f1f4c..d2a7432 100644 --- a/overrides/hive/example/pubspec.yaml +++ b/overrides/hive/example/pubspec.yaml @@ -5,7 +5,11 @@ environment: dependencies: hive: any + hive_ce: ^2.8.0 dependency_overrides: hive: - path: ../ + git: + url: https://github.com/IO-Design-Team/hive_ce + ref: f8172d4b88b195eea1b1d07e3397332dc77a91ae + path: overrides/hive