Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8ef95f5c32 | ||
|
|
c5c0316c3e | ||
|
|
a5381a5831 | ||
|
|
8127ca62b3 | ||
|
|
8ce5e57d87 | ||
|
|
a429c5fbce | ||
|
|
e756a361a1 | ||
|
|
a58c24902f | ||
|
|
0d59230633 | ||
|
|
9fab598d4c | ||
|
|
a296315a12 | ||
|
|
9ab94fbf10 | ||
|
|
7b1299607c | ||
|
|
0b1760abe6 | ||
|
|
d35de8653f | ||
|
|
80416c604d | ||
|
|
6448c33677 | ||
|
|
aede73fbe2 | ||
|
|
6960c2d470 | ||
|
|
96424c216f | ||
|
|
4e4ffd80d6 | ||
|
|
bef7b2af65 | ||
|
|
c7793d4462 | ||
|
|
d1e1018a12 | ||
|
|
0d8ef94d06 | ||
|
|
f55247ec9c |
@@ -1,2 +1,2 @@
|
|||||||
SHA512 (tomcli-0.1.1.tar.gz) = 4d35a2d1fea21f8a6040fa773a096c0f327d12d25e08a81498dd0fe4c1fc22192a7362bf1ab5cb2fbb4a7e29aa747dd80a3af4d321e1b66dc6e78f7bd12dfbb6
|
SHA512 (tomcli-0.10.1.tar.gz) = 5e41665f74cae42feab53b23268a5ff9bcc77a32e7ea6a23e8b5758495aad304e5addf3f82b5e9d6553221db6788d0bf378eccb1908d40a375ba34b8a9565b95
|
||||||
SHA512 (tomcli-0.1.1.tar.gz.asc) = 1c7e0e1b8f790ac6c5003eea44aabb40c03617a90210b10451646b222060291dce53b5b0d566aaab2c3c11d8b64f8c23bf693e63dc14a9af74fe39bcca07d178
|
SHA512 (tomcli-0.10.1.tar.gz.asc) = 138230ab12d1f32978752b4aa1547bb13b30536a6868bad2c64bbbe610e55f012f87bb1be65e0ed1ffbf0ce07b4b162dcb54dedd1c5ee3cb667e6f8992d5e085
|
||||||
|
|||||||
+137
-24
@@ -4,9 +4,34 @@
|
|||||||
# SPDX-License-Identifier: MIT
|
# SPDX-License-Identifier: MIT
|
||||||
# License text: https://spdx.org/licenses/MIT.html
|
# License text: https://spdx.org/licenses/MIT.html
|
||||||
|
|
||||||
|
# bconds:
|
||||||
|
# tests
|
||||||
|
# Run unit tests
|
||||||
|
# tomlkit
|
||||||
|
# Enable tomlkit and all extras
|
||||||
|
# manpages
|
||||||
|
# Build manpages using scdoc
|
||||||
|
# bootstrap
|
||||||
|
# Disable tomlkit dependencies and unit tests.
|
||||||
|
# Add ~bootstrap to %%dist
|
||||||
|
# Allows tomcli to be built early in the new Python bootstrap process.
|
||||||
|
|
||||||
|
%bcond bootstrap 0
|
||||||
|
%bcond tomlkit %[%{without bootstrap} && (%{undefined rhel} || %{defined epel})]
|
||||||
|
%bcond tests %{without bootstrap}
|
||||||
|
%bcond manpages %[%{undefined rhel} || %{defined epel}]
|
||||||
|
|
||||||
|
# Add minimal py3_test_envvars for EPEL 9
|
||||||
|
%if %{undefined py3_test_envvars}
|
||||||
|
%define py3_test_envvars %{shrink:
|
||||||
|
PYTHONPATH=%{buildroot}%{python3_sitelib}
|
||||||
|
PATH=%{buildroot}%{_bindir}:${PATH}
|
||||||
|
}
|
||||||
|
%endif
|
||||||
|
|
||||||
Name: tomcli
|
Name: tomcli
|
||||||
Version: 0.1.1
|
Version: 0.10.1
|
||||||
Release: 1%{?dist}
|
Release: 4%{?dist}
|
||||||
Summary: CLI for working with TOML files. Pronounced "tom clee."
|
Summary: CLI for working with TOML files. Pronounced "tom clee."
|
||||||
|
|
||||||
License: MIT
|
License: MIT
|
||||||
@@ -14,19 +39,21 @@ URL: https://sr.ht/~gotmax23/tomcli
|
|||||||
%global furl https://git.sr.ht/~gotmax23/tomcli
|
%global furl https://git.sr.ht/~gotmax23/tomcli
|
||||||
Source0: %{furl}/refs/download/v%{version}/tomcli-%{version}.tar.gz
|
Source0: %{furl}/refs/download/v%{version}/tomcli-%{version}.tar.gz
|
||||||
Source1: %{furl}/refs/download/v%{version}/tomcli-%{version}.tar.gz.asc
|
Source1: %{furl}/refs/download/v%{version}/tomcli-%{version}.tar.gz.asc
|
||||||
Source2: https://meta.sr.ht/~gotmax23.pgp
|
|
||||||
|
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
BuildRequires: gnupg2
|
|
||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
BuildRequires: %{py3_dist pytest}
|
%if %{with manpages}
|
||||||
|
BuildRequires: scdoc
|
||||||
|
%endif
|
||||||
|
|
||||||
# One of the TOML backends is required
|
# One of the TOML backends is required
|
||||||
Requires: (%{py3_dist tomcli[tomlkit]} or %{py3_dist tomcli[tomli]})
|
Requires: (%{py3_dist tomcli[tomlkit]} or %{py3_dist tomcli[tomli]})
|
||||||
|
%if %{with tomlkit}
|
||||||
# Prefer the tomlkit backend
|
# Prefer the tomlkit backend
|
||||||
Suggests: %{py3_dist tomcli[tomlkit]}
|
Suggests: %{py3_dist tomcli[tomlkit]}
|
||||||
# Recommend the 'all' extra
|
# Recommend the 'all' extra
|
||||||
Recommends: %{py3_dist tomcli[all]}
|
Recommends: %{py3_dist tomcli[all]}
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@@ -34,57 +61,143 @@ tomcli is a CLI for working with TOML files. Pronounced "tom clee."
|
|||||||
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%gpgverify -d0 -s1 -k2
|
|
||||||
%autosetup -p1
|
%autosetup -p1
|
||||||
|
|
||||||
|
|
||||||
%generate_buildrequires
|
%generate_buildrequires
|
||||||
%pyproject_buildrequires -x all,tomlkit,tomli,test
|
%{pyproject_buildrequires %{shrink:
|
||||||
|
-x tomli
|
||||||
|
%{?with_tomlkit:-x all,tomlkit}
|
||||||
|
%{?with_tests:-x test}
|
||||||
|
}}
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%pyproject_wheel
|
%pyproject_wheel
|
||||||
|
|
||||||
|
%if %{with manpages}
|
||||||
|
for page in doc/*.scd; do
|
||||||
|
dest="${page%.scd}"
|
||||||
|
scdoc <"${page}" >"${dest}"
|
||||||
|
done
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%pyproject_install
|
%pyproject_install
|
||||||
%pyproject_save_files tomcli
|
%pyproject_save_files tomcli
|
||||||
|
|
||||||
mkdir -p %{buildroot}%{bash_completions_dir}
|
%if %{with manpages}
|
||||||
mkdir -p %{buildroot}%{fish_completions_dir}
|
# Install manpages
|
||||||
mkdir -p %{buildroot}%{zsh_completions_dir}
|
install -Dpm 0644 doc/*.1 -t %{buildroot}%{_mandir}/man1
|
||||||
|
%endif
|
||||||
|
|
||||||
|
# Install shell completions
|
||||||
(
|
(
|
||||||
export PYTHONPATH="%{buildroot}%{python3_sitelib}"
|
export %{py3_test_envvars}
|
||||||
export _TYPER_COMPLETE_TEST_DISABLE_SHELL_DETECTION=1
|
%{python3} compgen.py \
|
||||||
for command in %{buildroot}%{_bindir}/tomcli*; do
|
--installroot %{buildroot} \
|
||||||
$command --show-completion=bash > "%{buildroot}%{bash_completions_dir}/$(basename $command)"
|
--bash-dir %{bash_completions_dir}
|
||||||
$command --show-completion=fish > "%{buildroot}%{fish_completions_dir}/$(basename $command).fish"
|
|
||||||
$command --show-completion=zsh > "%{buildroot}%{zsh_completions_dir}/_$(basename $command)"
|
|
||||||
done
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
# Smoke test
|
||||||
|
(
|
||||||
|
export %{py3_test_envvars}
|
||||||
|
TOMCLI="%{buildroot}%{_bindir}/tomcli"
|
||||||
|
cp pyproject.toml test.toml
|
||||||
|
name="$($TOMCLI get test.toml project.name)"
|
||||||
|
test "${name}" = "tomcli"
|
||||||
|
|
||||||
|
$TOMCLI set test.toml str project.name not-tomcli
|
||||||
|
newname="$($TOMCLI get test.toml project.name)"
|
||||||
|
test "${newname}" = "not-tomcli"
|
||||||
|
)
|
||||||
|
|
||||||
|
%pyproject_check_import
|
||||||
|
%if %{with tests}
|
||||||
%pytest
|
%pytest
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%pyproject_extras_subpkg -n tomcli all tomli tomlkit
|
%pyproject_extras_subpkg -n tomcli %{?with_tomlkit:all tomlkit} tomli
|
||||||
|
|
||||||
|
|
||||||
%files -f %{pyproject_files}
|
%files -f %{pyproject_files}
|
||||||
# I prefer not to rely on %%pyproject_save_files to mark files with %%license.
|
%license LICENSE
|
||||||
# Also, Fedora's hatchling supports the current draft of PEP 639, but EPEL 9's
|
|
||||||
# does not.
|
|
||||||
%license LICENSES/*.txt
|
|
||||||
%doc README.md
|
%doc README.md
|
||||||
%doc NEWS.md
|
%doc NEWS.md
|
||||||
%{_bindir}/tomcli*
|
%{_bindir}/tomcli*
|
||||||
%{bash_completions_dir}/tomcli*
|
%{bash_completions_dir}/tomcli*
|
||||||
%{fish_completions_dir}/tomcli*.fish
|
%if %{with manpages}
|
||||||
%{zsh_completions_dir}/_tomcli*
|
%{_mandir}/man1/tomcli*.1*
|
||||||
|
%endif
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Jan 17 2026 Fedora Release Engineering <releng@fedoraproject.org> - 0.10.1-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Sep 19 2025 Python Maint <python-maint@redhat.com> - 0.10.1-3
|
||||||
|
- Rebuilt for Python 3.14.0rc3 bytecode
|
||||||
|
|
||||||
|
* Fri Aug 15 2025 Python Maint <python-maint@redhat.com> - 0.10.1-2
|
||||||
|
- Rebuilt for Python 3.14.0rc2 bytecode
|
||||||
|
|
||||||
|
* Thu Jul 31 2025 Maxwell G <maxwell@gtmx.me> - 0.10.1-1
|
||||||
|
- Update to 0.10.1.
|
||||||
|
|
||||||
|
* Fri Jul 25 2025 Fedora Release Engineering <releng@fedoraproject.org> - 0.10.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Jun 06 2025 Maxwell G <maxwell@gtmx.me> - 0.10.0-1
|
||||||
|
- Update to 0.10.0.
|
||||||
|
|
||||||
|
* Tue Jun 03 2025 Python Maint <python-maint@redhat.com> - 0.9.0-2
|
||||||
|
- Rebuilt for Python 3.14
|
||||||
|
|
||||||
|
* Sun Mar 02 2025 Maxwell G <maxwell@gtmx.me> - 0.9.0-1
|
||||||
|
- Update to 0.9.0.
|
||||||
|
|
||||||
|
* Sun Jan 19 2025 Fedora Release Engineering <releng@fedoraproject.org> - 0.8.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
|
||||||
|
|
||||||
|
* Mon Sep 16 2024 Maxwell G <maxwell@gtmx.me> - 0.8.0-1
|
||||||
|
- Update to 0.8.0.
|
||||||
|
|
||||||
|
* Wed Aug 28 2024 Maxwell G <maxwell@gtmx.me> - 0.7.0-1
|
||||||
|
- Update to 0.7.0.
|
||||||
|
|
||||||
|
* Sat Jul 20 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.0-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Jun 07 2024 Python Maint <python-maint@redhat.com> - 0.6.0-2
|
||||||
|
- Rebuilt for Python 3.13
|
||||||
|
|
||||||
|
* Thu Mar 28 2024 Maxwell G <maxwell@gtmx.me> - 0.6.0-1
|
||||||
|
- Update to 0.6.0.
|
||||||
|
|
||||||
|
* Sat Jan 27 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.0-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Dec 22 2023 Maxwell G <maxwell@gtmx.me> - 0.5.0-2
|
||||||
|
- Fix installation of license files
|
||||||
|
|
||||||
|
* Thu Dec 14 2023 Maxwell G <maxwell@gtmx.me> - 0.5.0-1
|
||||||
|
- Update to 0.5.0.
|
||||||
|
|
||||||
|
* Thu Sep 07 2023 Maxwell G <maxwell@gtmx.me> - 0.3.0-1
|
||||||
|
- Update to 0.3.0.
|
||||||
|
|
||||||
|
* Sat Jul 22 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.2-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jun 29 2023 Python Maint <python-maint@redhat.com> - 0.1.2-2
|
||||||
|
- Rebuilt for Python 3.12
|
||||||
|
|
||||||
|
* Sat May 20 2023 Maxwell G <maxwell@gtmx.me> - 0.1.2-1
|
||||||
|
- Update to 0.1.2.
|
||||||
|
|
||||||
* Wed May 03 2023 Maxwell G <maxwell@gtmx.me> - 0.1.1-1
|
* Wed May 03 2023 Maxwell G <maxwell@gtmx.me> - 0.1.1-1
|
||||||
- Initial package. Closes rhbz#2186902.
|
- Initial package. Closes rhbz#2186902.
|
||||||
|
|||||||
Reference in New Issue
Block a user