Skip to content

Commit 19a70cc

Browse files
committed
Add new Dart 3.4 rules
1 parent f46826c commit 19a70cc

File tree

5 files changed

+38
-2
lines changed

5 files changed

+38
-2
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
# Changelog
22

3+
## 2.5.0
4+
5+
Requires Dart `sdk: '>=3.4.0'`
6+
7+
- Enable [`unnecessary_library_name`](https://dart-lang.github.io/linter/lints/unnecessary_library_name.html)
8+
- Enable [`missing_code_block_language_in_doc_comment`](https://dart-lang.github.io/linter/lints/missing_code_block_language_in_doc_comment.html)
9+
310
## 2.4.0
411

512
Requires Dart `sdk: '>=3.3.0'`

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ Generally, you can just put `lint: ^2.0.0` in your `pubspec.yaml` and pub get th
7979

8080
| Dart Version | Lint Version |
8181
|--------------|---------------------------------------------------------------------|
82+
| `3.4` | [`2.5.0`](https://pub.dev/packages/lint/versions/2.5.0/changelog) |
8283
| `3.3` | [`2.4.0`](https://pub.dev/packages/lint/versions/2.4.0/changelog) |
8384
| `3.2` | [`2.3.0`](https://pub.dev/packages/lint/versions/2.3.0/changelog) |
8485
| `3.1` | [`2.2.0`](https://pub.dev/packages/lint/versions/2.2.0/changelog) |

lib/casual.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -548,6 +548,13 @@ linter:
548548
# https://dart-lang.github.io/linter/lints/literal_only_boolean_expressions.html
549549
# - literal_only_boolean_expressions
550550

551+
# Code blocks in documentation comments should specify a language for better readability
552+
#
553+
# Dart SDK: >= 3.4.0
554+
#
555+
# https://dart.dev/tools/linter-rules/missing_code_block_language_in_doc_comment
556+
# - missing_code_block_language_in_doc_comment
557+
551558
# Don't forget the whitespaces at the end
552559
#
553560
# Dart SDK: >= 2.8.0-dev.10.0 • (Linter v0.1.110)
@@ -1032,6 +1039,13 @@ linter:
10321039
# https://dart-lang.github.io/linter/lints/unnecessary_library_directive.html
10331040
- unnecessary_library_directive
10341041

1042+
# Don't use unnecessary library names
1043+
#
1044+
# Dart SDK: >= 3.4.0
1045+
#
1046+
# https://dart.dev/tools/linter-rules/unnecessary_library_name
1047+
# - unnecessary_library_name
1048+
10351049
# Remove the optional `new` keyword
10361050
#
10371051
# https://dart-lang.github.io/linter/lints/unnecessary_new.html

lib/strict.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -549,6 +549,13 @@ linter:
549549
# https://dart-lang.github.io/linter/lints/literal_only_boolean_expressions.html
550550
# - literal_only_boolean_expressions
551551

552+
# Code blocks in documentation comments should specify a language for better readability
553+
#
554+
# Dart SDK: >= 3.4.0
555+
#
556+
# https://dart.dev/tools/linter-rules/missing_code_block_language_in_doc_comment
557+
- missing_code_block_language_in_doc_comment
558+
552559
# Don't forget the whitespaces at the end
553560
#
554561
# Dart SDK: >= 2.8.0-dev.10.0 • (Linter v0.1.110)
@@ -1026,6 +1033,13 @@ linter:
10261033
# https://dart-lang.github.io/linter/lints/unnecessary_late.html
10271034
- unnecessary_late
10281035

1036+
# Don't use unnecessary library names
1037+
#
1038+
# Dart SDK: >= 3.4.0
1039+
#
1040+
# https://dart.dev/tools/linter-rules/unnecessary_library_name
1041+
- unnecessary_library_name
1042+
10291043
# New library syntax, time to migrate
10301044
#
10311045
# Dart SDK: 2.19.0 • (Linter v1.29.0)

pubspec.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: lint
2-
version: 2.4.0
2+
version: 2.5.0
33
description: An opinionated, community-driven set of lint rules for Dart and Flutter projects. Like pedantic but stricter
44
repository: https://github.com/passsy/dart-lint
55
issue_tracker: https://github.com/passsy/dart-lint/issues
66
topics:
77
- lint
88

99
environment:
10-
sdk: '>=3.3.0 <4.0.0'
10+
sdk: '>=3.4.0 <4.0.0'

0 commit comments

Comments
 (0)