Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add 'unnecessary_library_name' to package:dart_flutter_team_lints #252

Merged
merged 5 commits into from
May 13, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
117 changes: 74 additions & 43 deletions .github/workflows/dart.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion pkgs/dart_flutter_team_lints/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
## 2.1.2-wip
## 2.2.0

- Added `unnecessary_library_name`.
- Require Dart `3.4`.

## 2.1.1

Expand Down
1 change: 1 addition & 0 deletions pkgs/dart_flutter_team_lints/lib/analysis_options.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ linter:
- sort_pub_dependencies
- unnecessary_lambdas
- unnecessary_library_directive
- unnecessary_library_name
- unnecessary_parenthesis
- unnecessary_statements
- use_is_even_rather_than_modulo
Expand Down
4 changes: 2 additions & 2 deletions pkgs/dart_flutter_team_lints/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
name: dart_flutter_team_lints
description: An analysis rule set used by the Dart and Flutter teams.
version: 2.1.2-wip
version: 2.2.0
repository: https://github.com/dart-lang/ecosystem/tree/main/pkgs/dart_flutter_team_lints

environment:
sdk: ^3.0.0
sdk: ^3.4.0

dependencies:
lints: ^3.0.0
Expand Down
18 changes: 7 additions & 11 deletions tool/ci.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
#!/bin/bash
# Created with package:mono_repo v6.6.0
# Created with package:mono_repo v6.6.1

# Support built in commands on windows out of the box.

# When it is a flutter repo (check the pubspec.yaml for "sdk: flutter")
# then "flutter" is called instead of "pub".
# then "flutter pub" is called instead of "dart pub".
# This assumes that the Flutter SDK has been installed in a previous step.
function pub() {
if grep -Fq "sdk: flutter" "${PWD}/pubspec.yaml"; then
Expand All @@ -12,18 +13,13 @@ function pub() {
command dart pub "$@"
fi
}
# When it is a flutter repo (check the pubspec.yaml for "sdk: flutter")
# then "flutter" is called instead of "pub".
# This assumes that the Flutter SDK has been installed in a previous step.

function format() {
if grep -Fq "sdk: flutter" "${PWD}/pubspec.yaml"; then
command flutter format "$@"
else
command dart format "$@"
fi
command dart format "$@"
}

# When it is a flutter repo (check the pubspec.yaml for "sdk: flutter")
# then "flutter" is called instead of "pub".
# then "flutter analyze" is called instead of "dart analyze".
# This assumes that the Flutter SDK has been installed in a previous step.
function analyze() {
if grep -Fq "sdk: flutter" "${PWD}/pubspec.yaml"; then
Expand Down
Loading