https://github.com/debacode/lint_maker
Custom dart linting maker. Creates analysis_options.yaml files to your liking.
https://github.com/debacode/lint_maker
analysis dart flutter lints
Last synced: 2 months ago
JSON representation
Custom dart linting maker. Creates analysis_options.yaml files to your liking.
- Host: GitHub
- URL: https://github.com/debacode/lint_maker
- Owner: debacode
- License: bsd-3-clause
- Created: 2023-08-31T14:56:29.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-12-12T10:39:52.000Z (over 1 year ago)
- Last Synced: 2024-12-12T11:33:16.548Z (over 1 year ago)
- Topics: analysis, dart, flutter, lints
- Language: Dart
- Homepage: https://pub.dev/packages/lint_maker
- Size: 77.1 KB
- Stars: 4
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Dart lint maker
Custom linting maker. Creates analysis_options.yaml files to your liking.
This package is useful if you want to either create your own linting package or just add a custom analysis_options.yaml file to your project.
## Setup:
Add lint_maker to your dev dependencies and create a `lint_maker.yaml` file in the root of your project.
The config can look something like:
```yaml
name: # internal name of the config
output: "analysis_options.yaml" # output file
preset: # The base analyzer config
analyzer:
language:
strict-casts: true
strict-inference: true
strict-raw-types: true
exclude:
- "**.g.dart"
linter:
rules:
always_specify_types: false
avoid_annotating_with_dynamic: false
avoid_as: false
avoid_print: false
diagnostic_describe_all_properties: false
prefer_double_quotes: false
prefer_relative_imports: false
unnecessary_final: false
prefer_final_parameters: false
prefer_expression_function_bodies: false
avoid_catches_without_on_clauses: false
```
You can specify multiple such configs in the same file.
### Update rules:
To update the rules you need to update the execute [lint_maker.dart](bin/lint_maker.dart) by running:
```sh
dart pub run lint_maker
```