## START: Set by rpmautospec ## (rpmautospec version 0.8.1) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 10; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec # Generated by go2rpm 1.17.1 %bcond check 1 %global sheets_commit 36bdb99dcfadde210503d8c2dcf94b34ee950e1d %global sheets_commit_short 36bdb99 # https://github.com/cheat/cheat %global goipath github.com/cheat/cheat Version: 4.4.2 %global tag 4.4.2 %gometa -L -f Name: cheat Release: %autorelease Summary: Help for various commands and their use cases # Generated by go-vendor-tools License: Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND ISC AND MIT URL: %{gourl} Source0: %{gosource} # Generated by go-vendor-tools Source1: %{archivename}-vendor.tar.bz2 Source2: go-vendor-tools.toml Source3: https://github.com/cheat/cheatsheets/archive/%{sheets_commit_short}.tar.gz Source4: cheat-config-FEDORA.yml BuildRequires: go-vendor-tools %if %{with check} # For tests a default editor is required BuildRequires: nano-default-editor %endif Recommends: cheat-community-cheatsheets %description Cheat allows you to create and view interactive cheatsheets on the command- line. It was designed to help remind *nix system administrators of options for commands that they use frequently, but not frequently enough to remember. # We wont use full versioned dependency because rpmdiff then complains about # difference between noarch subpackages on different architectures %package bash-completion Summary: Bash completion support for %{name} BuildArch: noarch Requires: %{name} = %{version}-%{release} Requires: bash bash-completion %description bash-completion Files needed to support bash completion. %package fish-completion Summary: Fish completion support for %{name} BuildArch: noarch Requires: %{name} = %{version}-%{release} Requires: fish %description fish-completion Files needed to support fish completion. %package zsh-completion Summary: Zsh completion support for %{name} BuildArch: noarch Requires: %{name} = %{version}-%{release} Requires: zsh %description zsh-completion Files needed to support zsh completion. %package community-cheatsheets Summary: Cheatsheets created by community for %{name} URL: https://github.com/cheat/cheatsheets # CC0-1.0 is for cheatsheets and is allowed as package predates 2022-08-01 ban License: CC0-1.0 BuildArch: noarch Requires: %{name} = %{version}-%{release} Supplements: cheat %description community-cheatsheets Cheatsheets for various programs created and maintained by the community. %prep %goprep -A %setup -q -T -D -a1 %{forgesetupargs} %autopatch -p1 # extract cheatsheets and remove license file as it's detected by # Go Vendor Tools and is not required for the main package, only for # community-cheatsheets subpackage %setup -q -T -D -a1 -a3 %{forgesetupargs} %generate_buildrequires %go_vendor_license_buildrequires -c %{S:2} %build %global gomodulesmode GO111MODULE=on %gobuild -o %{gobuilddir}/bin/cheat %{goipath}/cmd/cheat %install %go_vendor_license_install -c %{S:2} install -m 0755 -vd %{buildroot}%{_bindir} install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/ install -Dm 0644 -p scripts/cheat.bash %{buildroot}%{bash_completions_dir}/cheat install -Dm 0644 -p scripts/cheat.fish %{buildroot}%{fish_completions_dir}/cheat.fish install -Dm 0644 -p scripts/cheat.zsh %{buildroot}%{zsh_completions_dir}/_cheat # Install cheatsheets mkdir -m 0755 -p %{buildroot}/%{_datadir}/cheat mkdir -m 0755 -p %{buildroot}/%{_datadir}/cheat/vim-plugins for sheet in `find cheatsheets-%{sheets_commit}/ -maxdepth 1 -type f`; do install -m 0644 -p $sheet %{buildroot}%{_datadir}/cheat/ done for sheet in `find cheatsheets-%{sheets_commit}/vim-plugins/ -maxdepth 1 -type f`; do install -m 0644 -p $sheet %{buildroot}%{_datadir}/cheat/ done mkdir -m 0755 -p %{buildroot}%{_sysconfdir}/cheat install -m 0644 -p %{SOURCE4} %{buildroot}%{_sysconfdir}/cheat/conf.yml %check %go_vendor_license_check -c %{S:2} %if %{with check} %gotest ./... %endif %files -f %{go_vendor_license_filelist} %license vendor/modules.txt %doc doc CONTRIBUTING.md README.md %config(noreplace) %{_sysconfdir}/cheat/conf.yml %{_bindir}/cheat %files community-cheatsheets %license cheatsheets-%{sheets_commit}/.github/LICENSE.txt %{_datadir}/cheat/ %files bash-completion %{bash_completions_dir}/cheat %files fish-completion %{fish_completions_dir}/cheat.fish %files zsh-completion %{zsh_completions_dir}/_cheat %changelog ## START: Generated by rpmautospec * Sat Aug 23 2025 Mikel Olasagasti Uranga - 4.4.2-10 - Adopt Go Vendor Tools * Fri Aug 15 2025 Maxwell G - 4.4.2-9 - Rebuild for golang-1.25.0 * Fri Aug 15 2025 Maxwell G - 4.4.2-8 - Revert "Rebuild for golang-1.25.0" * Fri Aug 15 2025 Maxwell G - 4.4.2-7 - Rebuild for golang-1.25.0 * Wed Jul 23 2025 Fedora Release Engineering - 4.4.2-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild * Thu Jan 16 2025 Fedora Release Engineering - 4.4.2-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild * Sat Aug 10 2024 Davide Cavalca - 4.4.2-4 - fixup: convert license to SPDX * Wed Aug 07 2024 Miroslav Suchý - 4.4.2-3 - convert license to SPDX * Wed Jul 17 2024 Fedora Release Engineering - 4.4.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild * Fri Mar 08 2024 Mikel Olasagasti Uranga - 4.4.2-1 - Update to 4.4.2 - Closes rhbz#2012518 * Sun Feb 11 2024 Maxwell G - 4.2.2-11 - Rebuild for golang 1.22.0 * Tue Jan 23 2024 Fedora Release Engineering - 4.2.2-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Fri Jan 19 2024 Fedora Release Engineering - 4.2.2-9 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Wed Jul 19 2023 Fedora Release Engineering - 4.2.2-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild * Wed Jan 18 2023 Fedora Release Engineering - 4.2.2-7 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild * Wed Jul 20 2022 Fedora Release Engineering - 4.2.2-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Tue Jul 19 2022 Maxwell G - 4.2.2-5 - Rebuild for CVE-2022-{1705,32148,30631,30633,28131,30635,30632,30630,1962} in golang * Fri Jun 17 2022 Robert-André Mauchin - 4.2.2-4 - Rebuilt for CVE-2022-1996, CVE-2022-24675, CVE-2022-28327, CVE-2022-27191, CVE-2022-29526, CVE-2022-30629 * Wed Jan 19 2022 Fedora Release Engineering - 4.2.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Wed Jul 21 2021 Fedora Release Engineering - 4.2.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild * Wed Jun 09 2021 Tomas Korbar - 4.2.2-1 - Rebase to 4.2.2 - Resolves: rhbz#1955026 * Tue Jan 26 2021 Fedora Release Engineering - 4.2.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild * Tue Dec 15 2020 Tomas Korbar - 4.2.0-1 - Update to 4.2.0 * Thu Nov 19 2020 Tomas Korbar - 4.1.1-1 - Update to 4.1.1 * Mon Aug 31 2020 Tomas Korbar - 4.0.4-1 - Update to 4.0.4 * Mon Jul 27 2020 Fedora Release Engineering - 4.0.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild * Mon Jul 13 2020 Tomas Korbar - 4.0.2-1 - Update to 4.0.2 * Thu Jan 30 2020 Tomas Korbar - 3.6.0-1 - Rebase cheat to version 3.6.0 (#1793381) - Rebase cheatsheets to commit 18c9374 * Tue Jan 28 2020 Fedora Release Engineering - 3.2.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild * Tue Jan 14 2020 Tomas Korbar - 3.2.2-1 - Rebase cheat to version 3.2.2 (#1786883) * Mon Dec 16 2019 Tomas Korbar - 3.2.1-1 - Rebase cheat to version 3.2.1 (#1771683) * Thu Oct 03 2019 Miro Hrončok - 2.5.1-6 - Rebuilt for Python 3.8.0rc1 (#1748018) * Mon Aug 19 2019 Miro Hrončok - 2.5.1-5 - Rebuilt for Python 3.8 * Wed Jul 24 2019 Fedora Release Engineering - 2.5.1-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild * Mon Jul 01 2019 Tomas Korbar - 2.5.1-3 - Fix typo in fish completions folder - Related: 1716145 * Wed Jun 12 2019 Tomas Korbar - 2.5.1-2 - 1716145 - Package autocompletion files for cheat * Wed Feb 20 2019 Tomas Korbar - 2.5.1-1 - Specfile changed accordingly to review * Mon Jan 28 2019 Tomas Korbar tkorbar@redhat.com - 2.5.1-1 - Initial commit of package ## END: Generated by rpmautospec