Skip to content

'commitPrefixes' config triggers 'deprecated config' warning #4310

@abidkyo

Description

@abidkyo

Describe the bug

I got this warning when commitPrefixes is defined in the config.

Provided user config is deprecated but auto-fixable. Attempting to write fixed version back to file...
Success. New config written to /home/abidkyo/.config/lazygit/config.yml

The 'fixed' config contains just whitespace changes,
which the indentation is 4-spaces instead of 2-spaces.

I believe the bug is from #4261

To Reproduce

  1. Add the commitPrefixes config as described in
    https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#predefined-commit-message-prefix
  2. launch lazygit
  3. see the 'whitespace' changes in the config file
  4. quit lazygit and see the warning in the command-line

Expected behavior

  • no change of config file
  • if change is necessary, use 2-spaces indentation

Version info:
commit=101bbb0ac56a1cf594301f45bda22c551f1aa870, build date=2025-02-22T11:33:02Z, build source=binaryRelease, version=0.47.1, os=linux, arch=amd64, git version=2.43.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions