PackageTrack
Sign in Get early access

custom_lint

Lint rules are a powerful way to improve the maintainability of a project. Custom Lint allows package authors and developers to easily write custom lint rules.

0.8.1 727K downloads/mo #425 most downloaded on pub.dev invertase/dart_custom_lint

What this package is like to depend on

Last release 11 months ago

09 Sep 2025

Release timing varies

gaps range from 9 days to 5 months

Nearly every release is documented

notes for 59 of 59 stable releases

1 version withdrawn

withdrawn after publishing

4 years old

61 releases · first in 2022

1 release in the last 12 months

see the full history below

Release timeline

61 releases · Apr 2022 to Sep 2025
2023 2024 2025 2026
Release Pre-release Withdrawn

Releases

latest 60 of 61
  1. 0.8.1 09 Sep 2025
    Release notes

    custom_lint : 0.8.0 -> 0.8.1
    custom_lint_builder : 0.8.0 -> 0.8.1

    Open source →
    Release notes

    Support analyzer 8.0.0

    Open source →
  2. 0.8.0 25 Jul 2025
    Release notes

    custom_lint : 0.7.7 -> 0.8.0
    custom_lint_builder : 0.7.7 -> 0.8.0

    Open source →
    Release notes

    Support analyzer 7.5.0

    Open source →
  3. 0.7.7 25 Jul 2025 withdrawn
    Release notes

    custom_lint : 0.7.6 -> 0.7.7
    custom_lint_builder : 0.7.6 -> 0.7.7

    Open source →
  4. 0.7.6 18 Jul 2025
    Release notes

    Fix custom_lint not working on up-to-date Dart

    Open source →
  5. 0.7.5 27 Feb 2025
    Release notes

    Fix inconsistent version

    Open source →
  6. 0.7.4 27 Feb 2025
    Release notes
    • Upgrade Freezed to 3.0
    • Support Dart workspaces (thanks to @Rexios80)
    • Suppport analyzer_plugin 0.13.0 (thanks to @Rexios80)
    • Support custom hosted dependencies (thansk to @MobiliteDev)
    Open source →
  7. 0.7.3 08 Feb 2025
    Release notes
    • Bump analyzer_plugin
    Open source →
  8. 0.7.2 29 Jan 2025
    Release notes
    • Fix Android Studio/InteliJ (thanks to @EricSchlichting)
    Open source →
  9. 0.7.1 08 Jan 2025
    Release notes
    • Support analyzer 7.0.0
    Open source →
  10. 0.7.0 27 Oct 2024
    Release notes
    • custom_lint --fix and the generated "Fix all <code>" assists now correctly handle imports.
    • Now supports a broad number of analyzer version.
    Open source →
  11. 0.6.10 10 Oct 2024
    Release notes
    • Support installing custom_lint plugins in dependencies: instead of dev_dependencies (thanks to @dickermoshe).
    Open source →
  12. 0.6.9 09 Oct 2024
    Release notes
    • custom_lint_core upgraded to 0.6.9
    Open source →
  13. 0.6.8 08 Oct 2024
    Release notes
    • Fix CI
    • Fix custom_lint not warning non-Dart files when necessary.
    • Custom_lint no-longer tries to analyze projects that lack a .dart_tool/package_config.json
    Open source →
  14. 0.6.7 08 Sep 2024
    Release notes
    • Removed offline package resolution for the analyzer plugin. The logic seemed broken at times, so removing it should make custom_lint more stable.
    Open source →
  15. 0.6.6 08 Sep 2024
    Release notes
    • Fixed an error in the CLI when Flutter generates code under .dart_tool/ or has dependencies on iOS libraries (thanks to @Kurogoma4D)
    Open source →
  16. 0.6.5 15 Aug 2024
    Release notes
    • Upgraded to analyzer ^6.6.0. This is a quick fix to unblock the stable Flutter channel. A more robust fix will come later.
    • Fixed a bug where isSuperTypeOf throws if the element is null (thanks to @charlescyt)
    Open source →
  17. 0.6.4 16 Mar 2024
    Release notes
    • Improve error message to attempt debugging a certain bug
    Open source →
  18. 0.6.3 16 Mar 2024
    Release notes
    • Fixed Unimplemented error when running pub get.
    • Hot-reload and debug mode is now disabled by default.
    Open source →
  19. 0.6.2 19 Feb 2024
    Release notes
    • custom_lint --format json no-longer outputs non-JSON logs (thanks to @kzrnm)
    • Upgrade analyzer to support 6.4.0
    • Fix null exception when using TypeChecker.isSuperTypeOf (thanks to @charlescyt)
    Open source →
  20. 0.6.0 04 Feb 2024
    Release notes
    • Added support for --fix
    Open source →
  21. 0.5.11 27 Jan 2024
    Release notes
    • Added support for analysis_options.yaml that are nt at the root of the project (thanks to @mrgnhnt96)
    Open source →
  22. 0.5.8 09 Jan 2024
    Release notes
    • // ignore comments now correctly respect indentation when they are inserted (thanks to @PiotrRogulski)
    Open source →
  23. 0.5.7 20 Nov 2023
    Release notes
    • Support JSON output format via CLI parameter --format json|default (thanks to @kuhnroyal)
    Open source →
  24. 0.5.6 30 Oct 2023
    Release notes

    Optimized logic for finding an unused VM_service port.

    Open source →
  25. 0.5.5 26 Oct 2023
    Release notes
    • Support hotreloader 4.0.0
    Open source →
  26. 0.5.4 20 Oct 2023
    Release notes
    • Sort lints by severity in the command line (thanks to @kuhnroyal)
    • Fix watch mode not quitting with q (thanks to @kuhnroyal)
    • Improve the command line's output (thanks to @kuhnroyal)
    • Update uuid to 4.0.0
    • Fixed a port leak
    • Fix connection issues on Docker/windows (thanks to @hamsbrar)
    Open source →
  27. 0.5.3 29 Aug 2023
    Release notes
    • The command line now supports ignoring warnings/infos with --no-fatal-warnings/--no-fatal-infos (thanks to @yamarkz)
    Open source →
  28. 0.5.2 16 Aug 2023
    Release notes
    • Support both analyzer 5.12.0 and 6.0.0 at the same time.
    • Attempt at fixing the windows crash
    Open source →
  29. 0.5.1 03 Aug 2023
    Release notes

    Support analyzer v6

    Open source →
  30. 0.5.0 21 Jun 2023
    Release notes
    • Now resolves packages using pub get if custom_lint failed to resolve packages offline. This should reduce the likelyness of a version conflict in mono-repositories. The conflict may still happen if two projects in a mono-repo use incompatible constraints. Like:
      name: foo
      dependencies:
        package: ^1.0.0
      
      name: bar
      dependencies:
        package: ^2.0.0
      
    • The command line now shows the lints' severity (thanks to @praxder)
    • Now requires Dart 3.0.0
    Open source →
  31. 0.4.0 12 May 2023
    Release notes
    • Report uncaught exceptions inside context.addPostRunCallback
    • Added support for analyzer 5.12.0
    Open source →
  32. 0.3.4 19 Apr 2023
    Release notes
    • custom_lint now automatically generate quick-fixes for "ignore for line/file".
    • Update the socket communication logic to avoid possible problem is the message contains a \n.
    • fixes custom_lint on windows
    Open source →
  33. 0.3.3 06 Apr 2023
    Release notes
    • Reduce the likelyness of a dependency version conflict.
    • Fix dart analyze crashing on large projects in the CI due to custom_lint incorrectly trying to run plugins in debug mode.
    • Fix the custom_lint command line never terminating in some cases where plugins fail to start (thanks to @kuhnroyal).
    • Upgraded analyzer to >=5.7.0 <5.11.0
    • LintRuleNodeRegistry and other AstVisitor-like now are based off GeneralizingAstVisitor instead of GeneralizingAstVisitor
    • Upgraded cli_util to ^0.4.0
    • The command line no-longer throws if ran on an empty project or a project with no plugins enabled
    • Exposes the Pubspec in CustomLintContext
    Open source →
  34. 0.3.2 09 Mar 2023
    Release notes
    • Revert "Fixed an issue that caused a "Port already in use" error when trying to start custom_lint". This had the opposite effect of what's expected.
    Open source →
  35. 0.3.0 09 Mar 2023
    Release notes
    • Update analyzer to >=5.7.0 <5.8.0
    • Fixed an issue that caused a "Port already in use" error when trying to start custom_lint
    Open source →
  36. 0.2.12 28 Feb 2023
    Release notes

    Move json_serializable to dev dependencies

    Open source →
  37. 0.2.11 27 Feb 2023
    Release notes
    • Improved the error message when there is a version conflict in mono-repos (thanks to @@adsonpleal)
    • Bump minimum Dart SDK to sdk: ">=2.19.0 <3.0.0"
    Open source →
  38. 0.2.5 10 Feb 2023
    Release notes

    Fix custom_lint not correctly killing sub-processes when the IDE stops custom_lint.

    Open source →
  39. 0.2.2 31 Jan 2023
    Release notes

    Fixes an exception thrown when a project contains images.

    Open source →
  40. 0.2.0 20 Jan 2023
    Release notes

    Large Breaking change This new version introduces large changes to how lints/fixes/assists are defined.
    Long story short, besides the createPlugin method, the entire syntax changed.

    See the readme, examples, and docs around how to use the new syntax.

    The new syntax has multiple benefits:

    • It is now possible to enable/disable lints inside the analysis_options.yaml as followed:

      # optional
      include: path/to/another/analysis_options.yaml
      
      custom_lint:
        rules:
          # enable a lint rule
          - my_lint_rule
          # A lint rule that is explicitly disabled
          - another_lint_rule: false
      

      Enabling/disabling lints is supported by default with the new syntax. Nothing to do~

    • Performance improvement when using a large number of lints. The workload of analyzing files is now shared between lints.

    • The new syntax makes the code simpler to maintain. Before, the PluginBase.getLints rapidly ended-up doing too much. Now, it is simple to split the implementation in multiple bits

    Open source →
  41. 0.1.2-dev 10 Jan 2023 pre-release
    Release notes

    Do some internal refactoring as an attempt to fix #60

    Open source →
  42. 0.1.1 09 Jan 2023
    Release notes
    • Fix an issue where plugins were hot-reloaded when the file analyzed changed.
    • Optimized analysis such that PluginBase.getLints() is theorically not reinvoked unless the file analyzed changed.
    Open source →
  43. 0.1.0 06 Jan 2023
    Release notes
    • Breaking: The plugin entrypoint has moved.
      Plugins no-longer should define a /bin/custom_lint.dart file. Instead they should define a /lib/<my_package_name>.dart

    • Breaking: The plugin entrypoint is modified. Plugins no-longer define a "main", but instead define a createPlugin function:

      Before:

      // /bin/custom_lint.dart
      void main(List<String> args, SendPort sendPort) {
        startPlugin(sendPort, MyPlugin());
      }
      

      After:

      // /lib/<my_package_name.dart
      MyPlugin createPlugin() => MyPlugin();
      
    • Add assist support. Inside your plugins, you can now override handleGetAssists:

      import 'package:analyzer_plugin/protocol/protocol_generated.dart'
        as analyzer_plugin;
      
      class MyPlugin extends PluginBase {
        // ...
      
        Future<analyzer_plugin.EditGetAssistsResult> handleGetAssists(
          ResolvedUnitResult resolvedUnitResult, {
          required int offset,
          required int length,
        }) async {
            // TODO return some assists for the given offset
        }
      }
      
    Open source →
  44. 0.0.16 09 Dec 2022
    Release notes

    Fix expect_lint not working if the file doesn't contain any lint.

    Open source →
  45. 0.0.15 06 Dec 2022
    Release notes
    • Custom_lint now has a built-in mechanism for testing lints. Simply write a file that should contain lints for your plugin. Then, using a syntax similar to // ignore, write a // expect_lint: code in the line before your lint:

      // expect_lint: riverpod_final_provider
      var provider = Provider(...);
      

      When doing this, there are two possible cases:

      • The line after the expect_lint correctly contains the expected lint.
        In that case, the lint is ignored (similarly to if we used // ignore)
      • The next line does not contain the lint. In that case, the expect_lint comment will have an error.

      This allows testing your plugins by simply running custom_lint on your test/example folder. Then, if any expected lint is missing, the command will fail. But if your plugin correctly emits the lint, the command will succeed.

    • Upgrade analyzer/analzer_plugin

    Open source →
  46. 0.0.14 23 Nov 2022
    Release notes
    • Fix custom_lint not working in the IDE
    Open source →
  47. 0.0.13 23 Nov 2022
    Release notes
    • Add debugger and hot-reload support (Thanks to @TimWhiting)
    • Correctly respect exclude obtains from the analysis_options.yaml
    • Fix dart analyze incorrectly failing due to showing the "plugin is starting" lint.
    Open source →
  48. 0.0.12 07 Oct 2022
    Release notes
    • Fix custom_lint plugins not working in release mode and when using git dependencies (thanks to @TimWhiting)
    • Fix command line exit code not being set properly (thansk to @andrzejchm)
    Open source →
  49. 0.0.11 07 Oct 2022
    Release notes

    Fix custom_lint not showing in the IDE

    Open source →
  50. 0.0.10 03 Oct 2022
    Release notes
    • Upgrade Riverpod to 2.0.0
    • Fix deprecation errors with analyzer
    Open source →
  51. 0.0.10+1 04 Oct 2022
    Release notes

    Update docs

    Open source →
  52. 0.0.9 05 Jul 2022
    Release notes
    • Lint fixes can now be used when placing the cursor on the last character of a lint
    • improve pub score
    Open source →
  53. 0.0.9+1 06 Jul 2022
    Release notes

    Update description and readme

    Open source →
  54. 0.0.8 14 Jun 2022
    Release notes

    Allow lints to emit fixes

    Open source →
  55. 0.0.7 14 Jun 2022
    Release notes

    Fix a bug where the custom_lint command line may not list all lints

    Open source →
  56. 0.0.6 13 Jun 2022
    Release notes

    feat!: getLints now is expected to return a Stream<Lint> instead of Iterable<Lint>

    fix: a bug where the lints shown by the IDE could get out of sync with the actual content of the file

    Open source →
  57. 0.0.5 07 Jun 2022
    Release notes

    Fixed error reporting if a custom_lint plugin throws but the exception comes from a package instead of the plugin itself.

    Open source →
  58. 0.0.4 07 Jun 2022
    Release notes
    • Fixed a bug where the command line could show IDE-only meant for debugging
    Open source →
  59. 0.0.3 16 May 2022
    Release notes

    PluginBase.getLints now receive a ResolvedUnitResult instead of a LibraryElement.

    Open source →
  60. 0.0.2 14 Apr 2022
    Release notes
    • Compilation errors are now visible within the pubspec.yaml of applications that are using the plugin.

    • Plugins that are currently loading are now highlighted inside the pubspec.yaml of applications that are using the plugin.

    • If a plugin throws when trying to analyze a Dart file, the IDE will now show the exception at the top of the analyzed file.

    • Compilation errors, exceptions and prints are now accessible within a log file (custom_lint.log) inside applications using the plugin.

    Open source →

Every package, every release, already written down.

The archive is open and free. Watching your own project is what we are building next.

Browse the archive