#
# spec file for package inxi
#
# Copyright (c) 2025 SUSE LLC
# Copyright (c) 2011-2025 Malcolm J Lewis <malcolmlewis@opensuse.org>
#
# 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 _version 3.3.37-1
Name:           inxi
Version:        3.3.37
Release:        1.2
Summary:        A system information script
License:        GPL-3.0-or-later
URL:            https://codeberg.org/smxi/inxi
Source:         %{name}-%{_version}.tar.xz
Requires:       pciutils
Requires:       procps
Requires:       util-linux
Recommends:     Mesa-demo-x
Recommends:     bind-utils
Recommends:     dmidecode
Recommends:     iproute2
Recommends:     kmod-compat
Recommends:     sensors
Recommends:     tree
Recommends:     usbutils
Recommends:     perl(Cpanel::JSON::XS)
Recommends:     perl(Time::HiRes)
Recommends:     perl(XML::Dumper)
Suggests:       curl
Suggests:       freeipmi
Suggests:       hddtemp
Suggests:       sudo
Supplements:    (wmctrl and xorg-x11-server)
Supplements:    (xdpyinfo and xorg-x11-server)
Supplements:    (xprop and xorg-x11-server)
Supplements:    (xrandr and xorg-x11-server)
BuildArch:      noarch

%description
inxi is a command line system information tool. It was forked from
infobash. The primary purpose of inxi is for support, and sys admin
use. inxi is used widely for forum and IRC support.

%prep
%autosetup -n %{name}-%{_version}
sed -i '/^#!/s/env \(.*\)$/\1/' %{name}

%build
## Nothing to build.

%install
install -d -m 0755 %{buildroot}%{_bindir} %{buildroot}%{_mandir}/man1 \
                   %{buildroot}%{_datadir}/metainfo
install -m 0755 %{name} %{buildroot}%{_bindir}/%{name}
install -m 0644 %{name}.1 %{buildroot}%{_mandir}/man1/%{name}.1
install -m 0644 %{name}.metainfo.xml %{buildroot}%{_datadir}/metainfo/%{name}.metainfo.xml

%files
%license LICENSE.txt
%doc inxi.changelog README.txt
%{_bindir}/%{name}
%{_mandir}/man1/%{name}.1%{?ext_man}
%{_datadir}/metainfo/%{name}.metainfo.xml

%changelog
* Thu Jan  9 2025 malcolmlewis@opensuse.org
- Update to version 3.3.37:
  * This release is highlighted by a long overdue rewrite of the
  - b, -e, and -v[x] man page and help options. And changing the
    long incorrect -F/--full to -e/--expanded, which is more
    accurate. -e expands -b, that is, but is not full. -v8 is full.
  - F/--full will keep working until this inxi is in the stable
    repos of the major distros.
  * Renamed to inxi.metainfo.xml
  * Changed id to org.smxi.inxi
  * Added inxi.metadata.xml.
- Remove %%Check in spec file.
- Add installation of metainfo.
* Thu Sep  5 2024 malcolmlewis@opensuse.org
- Update to version 3.3.36:
  * Phase 2 of the big CPU upgrade a few years back is now done,
    I'd left one part inadequate in terms of the data structures,
    mainly because I did not have data samples to test, but also
    because no corner cases that required a more robust data
    structure for die > cluster > core counts showed up during the
    initial development phase. This led to somewhat predictable
    issues and bug reports when someone had a CPU that did require
    that structure to show correct core/die type data.
* Wed Jun 19 2024 malcolmlewis@opensuse.org
- Update to version 3.3.35:
  * Added more Wayland wm/de updates: wm, tools, lockers, etc.
  * Readme edit.
* Mon Apr 15 2024 malcolmlewis@opensuse.org
- Updated to version 3.3.34:
  + This is a nice point release that corrects and updates numerous
    smaller, and larger, features. Most pressing in terms of
    numbers affected was the failure to detect in display, non
    console, for Wayland without Xwayland running.
* Thu Apr  4 2024 malcolmlewis@opensuse.org
- Updated to version 3.3.33-1+3:
  + A quick point release, one critical bug fix, and a few new
    features and enhancements.
  + Code cleanup.
- Add service to pull from git and avoid tarball release.
- Adjust spec file for service use.
* Wed Feb  7 2024 malcolmlewis@opensuse.org
- Updated to version 3.3.33:
  + /usr/share/doc/packages/inxi/inxi.changelog.
* Wed Jan 31 2024 malcolmlewis@opensuse.org
- Updated to version 3.3.32:
  + /usr/share/doc/packages/inxi/inxi.changelog.
* Thu Nov 23 2023 malcolmlewis@opensuse.org
- Updated to version 3.3.31:
  + /usr/share/doc/packages/inxi/inxi.changelog.
- Updated spec file for new location of inxi at codeberg.org.
* Sun May 14 2023 malcolmlewis@opensuse.org
- Update to version 3.3.27:
  + /usr/share/doc/packages/inxi/inxi.changelog.
* Wed Nov 23 2022 Dominique Leuenberger <dimstar@opensuse.org>
- Update to version 3.3.23:
  + /usr/share/doc/packages/inxi/inxi.changelog.
* Fri Sep  2 2022 malcolmlewis@opensuse.org
- Updated to version 3.3.21:
  * /usr/share/doc/packages/inxi/inxi.changelog.
* Wed Aug 17 2022 Dirk Müller <dmueller@suse.com>
- update to 3.3.20:
  1a. More or less completed verification of AMD cpu microarch/built/process, and
  added more accurate fallback cases for stray model IDs.
  1b. Extended Intel cpu data a bit more as well. Thanks linuxdaddy from slackware
  for the research help there.
  2. Tentative support for finit init system (fast init). Runs in /proc/1/comm,
  uses initctl, which may have been revived from its upstart days, not sure. Added
  potential support for nosh, linux only, don't know how to detect other bsd init
  system.
  3. Added amd/intel gpu product IDs.
  4. Added shortcut --filter-all/--za, activates all filters: -z, --zl, --zu,
  - -zv. Why not?
  5. Added support for dm types kdmctl and xdmctl, opensuse and maybe redhat use
  the latter to start the actual dm running the desktop/wm. You want to see that
  because you need to do systemctl restart xdm to restart the actual dm. Thanks
  mrmazda for pointing out this one.
  6. Added AlmaLinux, RockyLinux, CentosStream to system base (RHEL derived).
  7. Basic Raptor Lake gpu/apu support added, with patterns to detect since few
  product ids yet. Same applies to Arctic and Alchemist, which still have no
  product IDs.
  8. More disk vendors and disk vendor ids, never stops - the waters flow on, the
  rain falls, then the sun comes out. Until one day it doesn't.
  * /usr/share/doc/packages/inxi/inxi.changelog.
* Mon Jun 20 2022 malcolmlewis@opensuse.org
- Updated to version 3.3.19:
  * /usr/share/doc/packages/inxi/inxi.changelog.
* Tue Jun 14 2022 malcolmlewis@opensuse.org
- Updated to version 3.3.18:
  * /usr/share/doc/packages/inxi/inxi.changelog.
* Sun Jun 12 2022 malcolmlewis@opensuse.org
- Updated to version 3.3.17:
  * /usr/share/doc/packages/inxi/inxi.changelog.
* Tue May 31 2022 malcolmlewis@opensuse.org
- Updated to version 3.3.16:
  * /usr/share/doc/packages/inxi/inxi.changelog.
- Spec file clean up.
* Sat Oct 16 2021 Dirk Müller <dmueller@suse.com>
- update to 3.3.07:
  * /usr/share/doc/packages/inxi/inxi.changelog.
* Tue Mar 23 2021 malcolmlewis@opensuse.org
- Updated to version 3.3.03:
  * See /usr/share/doc/packages/inxi/inxi.changelog.
* Thu Apr 23 2020 Alexei Sorokin <sor.alexei@meowr.ru>
- Update to version 3.1.00:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Fri Mar 20 2020 Alexei Sorokin <sor.alexei@meowr.ru>
- Update to version 3.0.38:
  * See /usr/share/doc/packages/inxi/inxi.changelog
- Drop support for old openSUSE versions.
* Mon Feb 18 2019 sor.alexei@meowr.ru
- Update to version 3.0.32:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Fri Jan 25 2019 seanlew@opensuse.org
- Update to version 3.0.30:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Sat Dec 15 2018 sor.alexei@meowr.ru
- Update to version 3.0.29:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Wed Dec  5 2018 sor.alexei@meowr.ru
- Update to version 3.0.28:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Thu Oct 25 2018 sor.alexei@meowr.ru
- Update to version 3.0.27:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Sat Oct  6 2018 sor.alexei@meowr.ru
- Update to version 3.0.26:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Thu Aug  9 2018 sor.alexei@meowr.ru
- Update to version 3.0.20:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Sun Jul 22 2018 sor.alexei@meowr.ru
- Update to version 3.0.18:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Tue May 22 2018 sor.alexei@meowr.ru
- Update to version 3.0.10:
  * See /usr/share/doc/packages/inxi/inxi.changelog
- Add additional requirements (boo#1085951).
* Wed Oct 18 2017 aavindraa@gmail.com
- Update to version 2.3.40:
  * See /usr/share/doc/packages/inxi/inxi.changelog
* Tue Jul 25 2017 sor.alexei@meowr.ru
- Update to version 2.3.25:
  * See https://github.com/smxi/inxi/blob/master/inxi.changelog
* Wed Mar 15 2017 sor.alexei@meowr.ru
- Update to version 2.3.8 (changes since 2.3.5):
  * While default configs remain in /etc/inxi.conf, the user
    overrides now use $XDG_CONFIG_HOME for the config and
    $XDG_DATA_HOME for the log/debugger data, which were previously
    in $HOME/.inxi.
    If neither of these cases are present, inxi will default to its
    legacy user data directory: $HOME/.inxi as before.
    In order to make this switch transparent to users, inxi will
    move the files to the new location.
  * Add some more XDG debugger data to cover this for future
    debugger data.
  * Fix manual inxi install not putting man pages in
    /usr/local/share/man/man1, which had caused an issue with the
    Arch linux inxi installer.
  * Small text changes and cleanup and updates in man page.
  * Fix a sloppy regex removing the BIOS from BIOSTAR.
  * Fix a few other sloppy gsub, and a few gensub errors as well.
  * Add a sisimedia video driver to the support list.
* Sun Dec  4 2016 sor.alexei@meowr.ru
- Update to version 2.3.5:
  * Fix inxi failing to add 'modesetting' graphics driver, which
    caused inxi to not show it in the output, which causes support
    issues for users of that specific driver, like some cases with
    Intel.
    Also inxi was failing to show it unloaded in cases where
    radeon/nouveau was used but it had been loaded by xorg to begin
    with.
* Sat Nov  5 2016 jengelh@inai.de
- Update package description
* Sat Nov  5 2016 sor.alexei@meowr.ru
- Update to version 2.3.4.1 (changes since 2.3.3.1):
  * Improve -D output, now capacity is on its own line, and each
    disc is on its own line always, this makes it easier to read
    and/or parse.
  * The lines now wrap nicely for extra data > console width, or
  - y 80 for example if one is trying to force most of the data to
    fit into 80 columns.
  * Added to -m if valid output, and if no -I or -tm triggers used,
    will show system ram used/total, from the -I line.
* Wed Nov  2 2016 sor.alexei@meowr.ru
- Update to version 2.3.3.1 (changes since 2.3.0):
  * Add basic support for Budgie desktop detection.
    This is waiting more data, so the support will be missing the
    version information.
  * Add /var/tmp and /var/log and /opt to basic partition data: -P
  * Modify the static BIOS in -M to now show UEFI for actually UEFI
    booted systems, and, ideally, UEFI [Legacy] for UEFI booting
    with MBR (BIOS legacy mode), and BIOS for all others.
  * Add device type show to -M: like desktop, laptop, notebook,
    server, blade, vm (and try to get vm type).
- Use the GitHub generated tarball using a commit hash.
- Include the licence file.
* Sat May 14 2016 malcolmlewis@opensuse.org
- Updated to version 2.3.0:
  + See https://github.com/smxi/inxi/commits/master for updates.
- Spec file cleanup to point at github.
* Mon Oct 12 2015 malcolmlewis@opensuse.org
- Updated to version 2.2.28:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2607.
  + Last googlecode release, project moved to github.
* Thu Jul 23 2015 malcolmlewis@opensuse.org
- Updated to version 2.2.26:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2605.
* Thu Jul  2 2015 malcolmlewis@opensuse.org
- Updated to version 2.2.25:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2604.
* Sun May 17 2015 malcolmlewis@opensuse.org
- Updated to version 2.2.21:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2595.
* Wed Feb 25 2015 malcolmlewis@opensuse.org
- Updated to version 2.2.19:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2592.
* Thu Feb  5 2015 malcolmlewis@opensuse.org
- Updated to version 2.2.18:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2585.
* Thu Nov 20 2014 malcolmlewis@opensuse.org
- Updated to version 2.2.16:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2581.
* Fri Aug 15 2014 malcolmlewis@opensuse.org
- Updated to version 2.1.95:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2376.
* Thu Jun  5 2014 malcolmlewis@cableone.net
- Updated to version 2.1.28:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2324.
* Sun Apr  6 2014 malcolmlewis@opensuse.org
- Updated to version 2.1.18:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2197.
* Mon Feb 10 2014 malcolmlewis@opensuse.org
- Updated to version 1.9.18:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2065.
* Fri Nov  1 2013 malcolmlewis@opensuse.org
-  Updated to version 1.9.16:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2055.
* Tue Oct 15 2013 malcolmlewis@opensuse.org
- Updated to version 1.9.16:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2053.
* Sun Sep  1 2013 malcolmlewis@opensuse.org
- Updated to version 1.9.14:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2038.
* Wed Aug  7 2013 malcolmlewis@opensuse.org
- Updated to version 1.9.12:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r2033.
* Thu May  9 2013 malcolmlewis@opensuse.org
- Updated to version 1.8.47:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1985.
* Mon Mar  4 2013 malcolmlewis@opensuse.org
- Updated to version 1.8.45:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1983.
* Fri Feb 15 2013 malcolmlewis@opensuse.org
- Updated to version 1.8.37:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1883.
- Add inxi.changelog to package.
* Sun Jan 20 2013 malcolmlewis@opensuse.org
- Updated to version 1.8.28:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1722.
* Sat Nov 24 2012 malcolmlewis@opensuse.org
- Updated to version 1.8.23:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1693.
* Tue Oct  9 2012 malcolmlewis@opensuse.org
- Updated to version 1.8.19:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1663.
  + Manual page changed to .1 from .8.
* Sat Sep  8 2012 malcolmlewis@opensuse.org
- Updated to version 1.8.14:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1605.
* Tue Jun 19 2012 malcolmlewis@opensuse.org
- Updated to version 1.8.5:
  + See http://code.google.com/p/inxi/source/list for updates
    upto and including r1551.
* Sat Apr 21 2012 malcolmlewis@opensuse.org
- Updated to version 1.7.33:
  + Adding in validation since user set ip addresses can be wrong.
- Updates from version 1.7.32:
  + Added feature where a different ip page can be added by
    whoever.
* Thu Apr 12 2012 malcolmlewis@opensuse.org
- Updated to version 1.7.31:
  + Updated recommends for arch, xprop has changed to xorg-xprop.
  + Added support, as root user, for dmidecode in -M data.
  + Language updates.
* Thu Mar 22 2012 malcolmlewis@opensuse.org
- Updated to version 1.7.30:
  + Bug fix, some intel cpus give core id as 0 for each core, thus
    creating a situation where inxi thinks it's a single core cpu,
    no matter if it's multicpu or multicore.
* Wed Feb 15 2012 malcolmlewis@opensuse.org
- Updated to version 1.7.29:
  + Fixed a logging bug, won't have any impact on users.
* Sun Feb  5 2012 malcolmlewis@opensuse.org
- Updated to version 1.7.28:
  + Small bug fix, added separator character to Desktop item, that
    was left out.
- Updates from version 1.7.27:
  + Added in aptosid-version and siduction-version to save
    maintainers time of adding those.
  + Big bug fix, usb networking output has apparently not worked
    for a long time, that is now fixed.
- Updates from version 1.7.26:
  + Bug fix, first patch, usb networking wasn't working.
- Updates from version 1.7.25:
  + Not showing speed/duplex for lan card when it is down.
* Sat Oct 22 2011 malcolmlewis@opensuse.org
- Initial build.