/pre-commit-beancount-format

Format beancount files using bean-format

Primary LanguagePythonGNU General Public License v2.0GPL-2.0

pre-commit-beancount-format

Format .beancount files using bean-format

Usage

Add this to your .pre-commit-config.yaml:

- repo: https://github.com/whtsky/pre-commit-beancount-format
  rev: "2.3.4" # Use the sha / tag you want to point at
  hooks:
    - id: beancount-format

Or, if you use .bean as your beancount files' extensions rather than .beancount:

- repo: https://github.com/whtsky/pre-commit-beancount-format
  rev: "2.3.4" # Use the sha / tag you want to point at
  hooks:
    - id: beancount-format
      files: \.bean$

To use custom arguments:

- repo: https://github.com/whtsky/pre-commit-beancount-format
  rev: "2.3.4" # Use the sha / tag you want to point at
  hooks:
    - id: beancount-format
      args: ["--currency-column=60"]