From 118f211bbc39ccf45e33ea68c161961f6e4b8063 Mon Sep 17 00:00:00 2001 From: Aaron Madlon-Kay Date: Wed, 4 Sep 2024 22:29:17 +0900 Subject: [PATCH] Add LineReader license --- assets/licenses/LICENSE-LineReader.txt | 21 +++++++++++++++++++++ lib/main.dart | 10 ++++++++-- pubspec.yaml | 1 + 3 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 assets/licenses/LICENSE-LineReader.txt diff --git a/assets/licenses/LICENSE-LineReader.txt b/assets/licenses/LICENSE-LineReader.txt new file mode 100644 index 0000000..9dff81e --- /dev/null +++ b/assets/licenses/LICENSE-LineReader.txt @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 andrewwoz + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/lib/main.dart b/lib/main.dart index 91cc477..965d794 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -10,8 +10,14 @@ import 'package:orgro/theme.dart'; void main() { LicenseRegistry.addLicense(() async* { - final license = await rootBundle.loadString('assets/fonts/OFL.txt'); - yield LicenseEntryWithLineBreaks(['google_fonts'], license); + yield LicenseEntryWithLineBreaks( + ['google_fonts'], + await rootBundle.loadString('assets/fonts/OFL.txt'), + ); + yield LicenseEntryWithLineBreaks( + ['LineReader'], + await rootBundle.loadString('assets/licenses/LICENSE-LineReader.txt'), + ); }); if (kReleaseMode) { diff --git a/pubspec.yaml b/pubspec.yaml index 81abe3f..7acda24 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -64,6 +64,7 @@ flutter: - assets/manual/data/C2/59CE94-D4C8-4C4F-9C9E-9ABE446E7DA3/ - assets/fonts/ - assets/test/ + - assets/licenses/ dependency_overrides: # Work around Dart 3.5.0 breakage: https://stackoverflow.com/q/69553108