%global pypi_name beancount-dkb
%global pypi_version 0.13.0

Name:           python-%{pypi_name}
Version:        %{pypi_version}
Release:        1%{?dist}
Summary:        Beancount Importer for DKB CSV exports

License:        None
URL:            https://github.com/siddhantgoel/beancount-dkb
Source0:        https://github.com/siddhantgoel/beancount-dkb/archive/%{pypi_version}/%{pypi_name}-%{pypi_version}.tar.gz
BuildArch:      noarch

BuildRequires:  python3-devel

%generate_buildrequires
%pyproject_buildrequires

%description
 Beancount DKB Importer[![image]( provides an Importer for converting CSV
exports of [DKB] (Deutsche Kreditbank) account summaries to the [Beancount]
format.

%package -n     python3-%{pypi_name}
Summary:        %{summary}
%{?python_provide:%python_provide python3-%{pypi_name}}

%description -n python3-%{pypi_name}
 Beancount DKB Importer[![image]( provides an Importer for converting CSV
exports of [DKB] (Deutsche Kreditbank) account summaries to the [Beancount]
format.


%prep
%autosetup -n %{pypi_name}-%{pypi_version}


%build
%pyproject_wheel


%install
%pyproject_install
%pyproject_save_files beancount_dkb
# remove spurious textfiles
rm %{buildroot}%{python3_sitelib}/LICENSE.txt  %{buildroot}%{python3_sitelib}/README.md



%files -n python3-%{pypi_name} -f %{pyproject_files}
%license LICENSE.txt
%doc README.md


%changelog
* Sun Jun 05 2022 Felix Kaechele <felix@kaechele.ca> - 0.13.0-1
- Initial package.