File wtfis.spec of Package wtfis

#
# spec file for package wtfis
#
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


#%%define skip_python38 1
%define upname  wtfis
Name:           wtfis
Version:        0.13.0
Release:        0
Summary:        Passive host and domain name lookup tool for non-robots
License:        MIT
URL:            https://github.com/pirxthepilot/wtfis
Source0:        https://github.com/pirxthepilot/wtfis/archive/refs/tags/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
BuildRequires:  %{python_module hatchling}
BuildRequires:  %{python_module pip}
BuildRequires:  %{python_module wheel}
Requires:       python-python-dotenv
Requires:       python-pydantic
Requires:       python-requests
Requires:       python-rich
Requires(post):   update-alternatives
Requires(postun):  update-alternatives
BuildArch:      noarch
%python_subpackages

%description
wtfis is a commandline tool that gathers information about a domain or FQDN
using various OSINT services. Unlike other tools of its kind, it's built
specifically for human consumption, providing results that are pretty (YMMV)
and easy to read and understand.

This tool assumes that you are using free tier / community level accounts, and
so makes as few API calls as possible to minimize hitting quotas and rate
limits.

The project name is a play on "whois".

%prep
%autosetup -p1

%build
%pyproject_wheel

%install
%pyproject_install

%python_expand %fdupes %{buildroot}%{$python_sitelib}

%python_clone -a %{buildroot}%{_bindir}/%{upname}

%post
%python_install_alternative %{upname}

%postun
%python_uninstall_alternative %{upname}

%files %{python_files}
%license LICENSE
%doc README.md
%python_alternative %{_bindir}/%{upname}
%{python_sitelib}/%{upname}
%{python_sitelib}/%{upname}-%{version}.dist-info

%changelog

openSUSE Build Service is sponsored by