From 6bdaa545a1e8a862e1e0b5a14d276cc7fd10ced4 Mon Sep 17 00:00:00 2001 From: YumNumm Date: Fri, 29 Nov 2024 20:26:08 +0900 Subject: [PATCH] execute `melos format` --- app/lib/core/component/chip/depth_filter_chip.dart | 2 +- .../core/component/chip/intensity_filter_chip.dart | 2 +- .../core/component/chip/magnitude_filter_chip.dart | 2 +- .../core/component/container/bordered_container.dart | 2 +- .../intenisty/jma_forecast_intensity_icon.dart | 2 +- .../intenisty/jma_forecast_lg_intensity_icon.dart | 2 +- .../provider/application_documents_directory.dart | 3 +-- app/lib/core/provider/device_info.dart | 3 +-- .../core/provider/firebase/firebase_messaging.dart | 3 +-- app/lib/core/provider/secure_storage.dart | 3 +-- app/lib/core/provider/shared_preferences.dart | 3 +-- .../travel_time/data/travel_time_data_source.dart | 3 +-- .../home/features/kmoni/data/kmoni_data_source.dart | 5 ++--- tools/formatter/format.sh | 12 ------------ 14 files changed, 14 insertions(+), 33 deletions(-) delete mode 100755 tools/formatter/format.sh diff --git a/app/lib/core/component/chip/depth_filter_chip.dart b/app/lib/core/component/chip/depth_filter_chip.dart index 4cbb68095..b9e0090b0 100644 --- a/app/lib/core/component/chip/depth_filter_chip.dart +++ b/app/lib/core/component/chip/depth_filter_chip.dart @@ -58,7 +58,7 @@ class _DepthFilterModal extends HookWidget { this.currentMin = initialMin, this.currentMax = initialMax, }); - + final int? currentMin; final int? currentMax; diff --git a/app/lib/core/component/chip/intensity_filter_chip.dart b/app/lib/core/component/chip/intensity_filter_chip.dart index 04ff6a78e..4f1bb8574 100644 --- a/app/lib/core/component/chip/intensity_filter_chip.dart +++ b/app/lib/core/component/chip/intensity_filter_chip.dart @@ -60,7 +60,7 @@ class _IntensityFilterModal extends HookWidget { this.currentMin = initialMin, this.currentMax = initialMax, }); - + final JmaIntensity? currentMin; final JmaIntensity? currentMax; diff --git a/app/lib/core/component/chip/magnitude_filter_chip.dart b/app/lib/core/component/chip/magnitude_filter_chip.dart index 61c93f2ba..d061a7bb0 100644 --- a/app/lib/core/component/chip/magnitude_filter_chip.dart +++ b/app/lib/core/component/chip/magnitude_filter_chip.dart @@ -58,7 +58,7 @@ class _MagnitudeFilterModal extends HookWidget { this.currentMin = MagnitudeFilterChip.initialMin, this.currentMax = MagnitudeFilterChip.initialMax, }); - + final double? currentMin; final double? currentMax; diff --git a/app/lib/core/component/container/bordered_container.dart b/app/lib/core/component/container/bordered_container.dart index 6e9be94fd..d6f25ef71 100644 --- a/app/lib/core/component/container/bordered_container.dart +++ b/app/lib/core/component/container/bordered_container.dart @@ -14,7 +14,7 @@ class BorderedContainer extends StatelessWidget { this.onPressed, super.key, }); - + final Widget child; final Color? accentColor; final EdgeInsetsGeometry padding; diff --git a/app/lib/core/component/intenisty/jma_forecast_intensity_icon.dart b/app/lib/core/component/intenisty/jma_forecast_intensity_icon.dart index a60dc19fa..4e4c97138 100644 --- a/app/lib/core/component/intenisty/jma_forecast_intensity_icon.dart +++ b/app/lib/core/component/intenisty/jma_forecast_intensity_icon.dart @@ -115,7 +115,7 @@ class JmaForecastIntensityIcon extends ConsumerWidget { this.size = 50, this.showSuffix = true, }); - + final JmaForecastIntensity intensity; final IntensityIconType type; final double size; diff --git a/app/lib/core/component/intenisty/jma_forecast_lg_intensity_icon.dart b/app/lib/core/component/intenisty/jma_forecast_lg_intensity_icon.dart index 7c73c2e58..334957a49 100644 --- a/app/lib/core/component/intenisty/jma_forecast_lg_intensity_icon.dart +++ b/app/lib/core/component/intenisty/jma_forecast_lg_intensity_icon.dart @@ -15,7 +15,7 @@ class JmaForecastLgIntensityWidget extends ConsumerWidget { super.key, this.size = 50, }); - + final JmaForecastLgIntensity intensity; final IntensityIconType type; final double size; diff --git a/app/lib/core/provider/application_documents_directory.dart b/app/lib/core/provider/application_documents_directory.dart index c1262fde2..187b19daa 100644 --- a/app/lib/core/provider/application_documents_directory.dart +++ b/app/lib/core/provider/application_documents_directory.dart @@ -6,5 +6,4 @@ import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'application_documents_directory.g.dart'; @Riverpod(keepAlive: true) -Directory applicationDocumentsDirectory(Ref ref) => - throw UnimplementedError(); +Directory applicationDocumentsDirectory(Ref ref) => throw UnimplementedError(); diff --git a/app/lib/core/provider/device_info.dart b/app/lib/core/provider/device_info.dart index 08e09c145..ef41914ce 100644 --- a/app/lib/core/provider/device_info.dart +++ b/app/lib/core/provider/device_info.dart @@ -5,8 +5,7 @@ import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'device_info.g.dart'; @Riverpod(keepAlive: true) -AndroidDeviceInfo androidDeviceInfo(Ref ref) => - throw UnimplementedError(); +AndroidDeviceInfo androidDeviceInfo(Ref ref) => throw UnimplementedError(); @Riverpod(keepAlive: true) IosDeviceInfo iosDeviceInfo(Ref ref) => throw UnimplementedError(); diff --git a/app/lib/core/provider/firebase/firebase_messaging.dart b/app/lib/core/provider/firebase/firebase_messaging.dart index f184fb383..f64937d97 100644 --- a/app/lib/core/provider/firebase/firebase_messaging.dart +++ b/app/lib/core/provider/firebase/firebase_messaging.dart @@ -5,5 +5,4 @@ import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'firebase_messaging.g.dart'; @Riverpod(keepAlive: true) -FirebaseMessaging firebaseMessaging(Ref ref) => - FirebaseMessaging.instance; +FirebaseMessaging firebaseMessaging(Ref ref) => FirebaseMessaging.instance; diff --git a/app/lib/core/provider/secure_storage.dart b/app/lib/core/provider/secure_storage.dart index 551c502d0..5398a3044 100644 --- a/app/lib/core/provider/secure_storage.dart +++ b/app/lib/core/provider/secure_storage.dart @@ -5,8 +5,7 @@ import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'secure_storage.g.dart'; @Riverpod(keepAlive: true) -FlutterSecureStorage secureStorage(Ref ref) => - const FlutterSecureStorage( +FlutterSecureStorage secureStorage(Ref ref) => const FlutterSecureStorage( aOptions: AndroidOptions( resetOnError: true, ), diff --git a/app/lib/core/provider/shared_preferences.dart b/app/lib/core/provider/shared_preferences.dart index 459d6d610..c56597b44 100644 --- a/app/lib/core/provider/shared_preferences.dart +++ b/app/lib/core/provider/shared_preferences.dart @@ -5,5 +5,4 @@ import 'package:shared_preferences/shared_preferences.dart'; part 'shared_preferences.g.dart'; @Riverpod(keepAlive: true) -SharedPreferences sharedPreferences(Ref ref) => - throw UnimplementedError(); +SharedPreferences sharedPreferences(Ref ref) => throw UnimplementedError(); diff --git a/app/lib/core/provider/travel_time/data/travel_time_data_source.dart b/app/lib/core/provider/travel_time/data/travel_time_data_source.dart index 39af6e1f2..929834343 100644 --- a/app/lib/core/provider/travel_time/data/travel_time_data_source.dart +++ b/app/lib/core/provider/travel_time/data/travel_time_data_source.dart @@ -6,8 +6,7 @@ import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'travel_time_data_source.g.dart'; @Riverpod(keepAlive: true) -TravelTimeDataSource travelTimeDataSource(Ref ref) => - TravelTimeDataSource(); +TravelTimeDataSource travelTimeDataSource(Ref ref) => TravelTimeDataSource(); class TravelTimeDataSource { Future> loadTables() async { diff --git a/app/lib/feature/home/features/kmoni/data/kmoni_data_source.dart b/app/lib/feature/home/features/kmoni/data/kmoni_data_source.dart index 4ac8a64bd..54531056c 100644 --- a/app/lib/feature/home/features/kmoni/data/kmoni_data_source.dart +++ b/app/lib/feature/home/features/kmoni/data/kmoni_data_source.dart @@ -10,12 +10,11 @@ import 'package:riverpod_annotation/riverpod_annotation.dart'; part 'kmoni_data_source.g.dart'; @Riverpod(keepAlive: true) -KmoniDataSource kmoniDataSource(Ref ref) => - KmoniDataSource(Dio()); +KmoniDataSource kmoniDataSource(Ref ref) => KmoniDataSource(Dio()); class KmoniDataSource { KmoniDataSource(this.dio); - + final Dio dio; final _urlGenerator = KmoniWebApiUrlGenerator(); diff --git a/tools/formatter/format.sh b/tools/formatter/format.sh deleted file mode 100755 index a9af1ea2a..000000000 --- a/tools/formatter/format.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -files=$(find lib -name "*.dart" -not \( -name "*.*freezed.dart" -o -name "*.*g.dart" -o -name "*.gen.dart" \)) -echo "Formatting files: $files" -for file in "$files"; do - # limit jobs to 5 - if [ "$(jobs -r | wc -l)" -ge 5 ]; then - wait "$(jobs -r -p | head -1)" - fi - dart fix --apply "$file" & -done -wait -dart format "$files"