Skip to content

pre-commit-hooks for pretty-format-json default behavior is misleading #602

Open
@staticdev

Description

@staticdev

Describe the bug
If I enable the hooks:

 git-hooks.hooks = {
    pretty-format-json.enable = true;
    check-json.enable = true;
  };

It will detect unformatted json but the file is not formatted after run.

To reproduce

Do what is in the description with any unformatted json.

If you change settings.autofix = true then it will behave as the original pre-commit hook.

In my opinion this should should not exist and be always true, it is false by default but a formatter is useless if it is not autofixing.

Version
devenv 1.6.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions