From fc27d51a01b7181d4208bbefa745f543dcc44be5 Mon Sep 17 00:00:00 2001 From: Fabian Freund Date: Fri, 5 Apr 2024 01:45:16 +0200 Subject: [PATCH] switch to lint package --- app/analysis_options.yaml | 36 +++++++++++++++++++++++++++++++++++- app/pubspec.yaml | 4 +--- 2 files changed, 36 insertions(+), 4 deletions(-) diff --git a/app/analysis_options.yaml b/app/analysis_options.yaml index f9b30346..eb484b1c 100644 --- a/app/analysis_options.yaml +++ b/app/analysis_options.yaml @@ -1 +1,35 @@ -include: package:flutter_lints/flutter.yaml +# This file configures the static analysis results for your project (errors, +# warnings, and lints). +# +# This enables the 'recommended' set of lints from `package:lints`. +# This set helps identify many issues that may lead to problems when running +# or consuming Dart code, and enforces writing Dart using a single, idiomatic +# style and format. +# +# If you want a smaller set of lints you can change this to specify +# 'package:lints/core.yaml'. These are just the most critical lints +# (the recommended set includes the core lints). +# The core lints are also what is used by pub.dev for scoring packages. + +include: package:lint/strict.yaml +# Uncomment the following section to specify additional rules. + +linter: + rules: + - unawaited_futures + - discarded_futures + - collection_methods_unrelated_type + +analyzer: + # plugins: + # - custom_lint + exclude: + - "**.g.dart" + - "**.swagger.dart" + - "**.freezed.dart" + - "**.chopper.dart" +# For more information about the core and recommended set of lints, see +# https://dart.dev/go/core-lints + +# For additional information about configuring this file, see +# https://dart.dev/guides/language/analysis-options diff --git a/app/pubspec.yaml b/app/pubspec.yaml index 44f80918..6aa5fd50 100644 --- a/app/pubspec.yaml +++ b/app/pubspec.yaml @@ -11,9 +11,7 @@ dependencies: sdk: flutter dev_dependencies: - flutter_test: - sdk: flutter - flutter_lints: ^3.0.0 + lint: ^2.3.0 flutter: uses-material-design: true