Add config show file name command

This commit is contained in:
Gabriel Augendre 2021-11-20 15:16:28 +01:00
parent b1f1950c98
commit dba4301eb6
2 changed files with 8 additions and 2 deletions

View file

@ -38,12 +38,18 @@ def config():
"""Manage configuration.""" """Manage configuration."""
@config.command("edit") @config.command("edit", help="Edit the config file.")
def edit_config(): def edit_config():
config_file = get_config_file_name() config_file = get_config_file_name()
click.edit(filename=config_file) click.edit(filename=config_file)
@config.command("file", help="Print the config file path.")
def show_file_name():
config_file = get_config_file_name()
click.echo(config_file)
@dataclass(frozen=True) @dataclass(frozen=True)
class Config: class Config:
account: str account: str

View file

@ -1,6 +1,6 @@
[tool.poetry] [tool.poetry]
name = "ofx-processor" name = "ofx-processor"
version = "3.1.0" version = "3.2.0"
description = "Personal ofx processor" description = "Personal ofx processor"
readme = "README.md" readme = "README.md"
license = "GPL-3.0-or-later" license = "GPL-3.0-or-later"