Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/melbournedeveloper/austerity
Dart and Flutter static code analysis, but not for the faint hearted
https://github.com/melbournedeveloper/austerity
analysis dart dartlang flutter lint linter static-analysis
Last synced: 3 months ago
JSON representation
Dart and Flutter static code analysis, but not for the faint hearted
- Host: GitHub
- URL: https://github.com/melbournedeveloper/austerity
- Owner: MelbourneDeveloper
- License: bsd-3-clause
- Created: 2022-09-18T00:54:29.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-02-01T03:19:36.000Z (12 months ago)
- Last Synced: 2024-10-12T01:25:54.974Z (3 months ago)
- Topics: analysis, dart, dartlang, flutter, lint, linter, static-analysis
- Language: Dart
- Homepage: https://pub.dev/packages/austerity
- Size: 312 KB
- Stars: 11
- Watchers: 3
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# austerity
You lack discipline! It's ok, though. This is like having discipline.This package attempts to use every Dart and Flutter code rule available that doesn't cause major headaches, is not incompatible with other rules, and turns the error severity up to error. That means the code will display errors when you do something wrong. Use this package to get the strongest warnings about code violations, and use `analysis_options.yaml` to dial it back when you need to.
This is what you will see when you do naughty things
![errors](https://github.com/MelbourneDeveloper/austerity/blob/main/doc/images/errors.png)This library takes advantage of almost all the rules in Dart 3, but feel free to log any missing rules.
## Use the package
- Install the package in the `pubspec.yaml`
- Add this line at the top of your `analysis_options.yaml````yaml
include: package:austerity/analysis_options.yaml
```## Configure Rules
You can easily turn the rules off or change the severity to warning. I dialed down a couple of rules due to personal preference, but you can see all of these in the [comments](https://github.com/MelbourneDeveloper/austerity/blob/main/lib/analysis_options.yaml) and adjust these for yourself. You have to understand that there are two types of settings: linters and analyzer rules. Most analyzer rules have a corresponding linter. You can remove the linter or change the severity of the analyzer rule. See the official documentation [here](https://dart.dev/guides/language/analysis-options).![errors](https://github.com/MelbourneDeveloper/austerity/blob/main/doc/images/config.png)
## Avoiding Breaking Changes
These analysis options change regularly. If new linters appear for the language, they will appear here and break your code. To avoid this, use a specific version of this package.✔️ Stable
`austerity: 0.0.8-beta`❌ Potential Breaking Changes
`austerity: ^0.0.8-beta`