Skip to content
This repository has been archived by the owner on Aug 6, 2024. It is now read-only.

Commit

Permalink
Merge pull request #24 from blendthink/release/3.0.0
Browse files Browse the repository at this point in the history
Release/3.0.0
  • Loading branch information
blendthink authored Sep 6, 2022
2 parents 0a2f0f2 + 8794164 commit c466045
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 16 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
publish:
runs-on: ubuntu-latest

if: github.event.pull_request.merged == true && startswith(github.head_ref, 'release/')
if: github.event.pull_request.merged == true && startsWith(github.head_ref, 'release/')
steps:
- uses: actions/checkout@v3
- uses: dart-lang/setup-dart@v1
Expand Down
25 changes: 25 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,28 @@
## 3.0.0

- Bumped the minimum required Dart SDK version to `2.18.0`.
- Removed `exclude:` specification
- Use `ignore_for_file` with build.yaml instead.
- Removed `invalid_annotation_target: ignore`
- If you are using freezed, add it to analysis_options.yaml.
- Added Lints.
- `unnecessary_to_list_in_spreads`
- `unnecessary_null_aware_operator_on_extension_on_nullable`
- Removed Lints.
- `invariant_booleans`

### Reference

- https://github.com/dart-lang/sdk/blob/main/CHANGELOG.md#2180
- https://pub.dev/packages/source_gen#configuring-combining_builder-ignore_for_file
- https://github.com/rrousselGit/freezed/issues/488
- https://github.com/dart-lang/linter/releases/tag/1.23.0
- https://github.com/dart-lang/linter/releases/tag/1.24.0
- https://github.com/dart-lang/linter/releases/tag/1.25.0
- https://dart-lang.github.io/linter/lints/unnecessary_to_list_in_spreads.html
- https://dart-lang.github.io/linter/lints/unnecessary_null_aware_operator_on_extension_on_nullable.html
- https://dart-lang.github.io/linter/lints/invariant_booleans.html

## 2.0.0

- Bumped the minimum required Dart SDK version to `2.17.5`.
Expand Down
10 changes: 5 additions & 5 deletions example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ packages:
path: ".."
relative: true
source: path
version: "1.0.0"
version: "3.0.0"
characters:
dependency: transitive
description:
name: characters
url: "https://pub.dartlang.org"
source: hosted
version: "1.2.0"
version: "1.2.1"
collection:
dependency: transitive
description:
Expand Down Expand Up @@ -47,14 +47,14 @@ packages:
name: material_color_utilities
url: "https://pub.dartlang.org"
source: hosted
version: "0.1.4"
version: "0.1.5"
meta:
dependency: transitive
description:
name: meta
url: "https://pub.dartlang.org"
source: hosted
version: "1.7.0"
version: "1.8.0"
sky_engine:
dependency: transitive
description: flutter
Expand All @@ -68,4 +68,4 @@ packages:
source: hosted
version: "2.1.2"
sdks:
dart: ">=2.17.0 <3.0.0"
dart: ">=2.18.0 <3.0.0"
2 changes: 1 addition & 1 deletion example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description: A example of blendthink_lints.
version: 1.0.0
publish_to: 'none'
environment:
sdk: '>=2.17.0 <3.0.0'
sdk: '>=2.18.0 <3.0.0'

dependencies:
flutter:
Expand Down
13 changes: 7 additions & 6 deletions lib/recommended.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@ analyzer:
errors: # https://dart.dev/tools/diagnostic-messages
missing_required_param: warning
missing_return: warning
invalid_annotation_target: ignore # Reason: https://github.com/rrousselGit/freezed/issues/488
exclude:
- "**/*.g.dart"
- "**/*.freezed.dart"
- "**/*.mocks.dart"

linter: # https://dart-lang.github.io/linter/lints/
rules:
Expand All @@ -25,7 +20,8 @@ linter: # https://dart-lang.github.io/linter/lints/
- close_sinks
- comment_references
#- diagnostic_describe_all_properties # use as you like
- invariant_booleans # experimental
#- discarded_futures # use as you like
#- invariant_booleans # deprecated
- literal_only_boolean_expressions
- no_adjacent_strings_in_list
#- prefer_relative_imports # exclude to use always_use_package_imports
Expand All @@ -40,6 +36,7 @@ linter: # https://dart-lang.github.io/linter/lints/
#- always_put_required_named_parameters_first # use as you like
#- always_specify_types # exclude to use avoid_types_on_closure_parameters, omit_local_variable_types
- avoid_annotating_with_dynamic
#- avoid_as # deprecated
- avoid_bool_literals_in_conditional_expressions
- avoid_catches_without_on_clauses
- avoid_catching_errors
Expand Down Expand Up @@ -83,6 +80,7 @@ linter: # https://dart-lang.github.io/linter/lints/
- parameter_assignments
- prefer_asserts_in_initializer_lists
#- prefer_asserts_with_message # use as you like
#- prefer_bool_in_asserts # deprecated
- prefer_constructors_over_static_methods
#- prefer_double_quotes # exclude to use prefer_single_quotes
#- prefer_expression_function_bodies # use as you like
Expand All @@ -100,15 +98,18 @@ linter: # https://dart-lang.github.io/linter/lints/
- sized_box_shrink_expand
- sort_constructors_first
- sort_unnamed_constructors_first
#- super_goes_last # deprecated
- tighten_type_of_initializing_formals
- type_annotate_public_apis
- unawaited_futures
- unnecessary_await_in_return
#- unnecessary_final # exclude to use prefer_final_locals
- unnecessary_lambdas
- unnecessary_null_aware_operator_on_extension_on_nullable
- unnecessary_null_checks # experimental
- unnecessary_parenthesis
- unnecessary_raw_strings
- unnecessary_to_list_in_spreads
- use_colored_box
- use_decorated_box
- use_enums # experimental
Expand Down
6 changes: 3 additions & 3 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
name: blendthink_lints
description: Recommended by blendthink set of lints for Flutter mobile apps to encourage good coding practices.
version: 2.0.0
version: 3.0.0
homepage: https://github.com/blendthink/flutter-mobile-lints

environment:
sdk: ">=2.17.5 <3.0.0"
sdk: ">=2.18.0 <3.0.0"

dependencies:
flutter_lints:
flutter_lints: ^2.0.1

dev_dependencies:
grinder: ^0.9.2

0 comments on commit c466045

Please sign in to comment.