## START: Set by rpmautospec ## (rpmautospec version 0.8.1) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; 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.16.0.post0 %bcond check 1 # https://gitlab.com/gitlab-org/cli %global goipath gitlab.com/gitlab-org/cli %global forgeurl https://gitlab.com/gitlab-org/cli Version: 1.61.0 %global tag v%{version} %gometa -L -f Name: glab Release: %autorelease Summary: A GitLab CLI tool bringing GitLab to your command line # Generated by go-vendor-tools License: Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause AND ISC AND MIT AND MPL-2.0 AND (FTL OR GPL-2.0-or-later) URL: %{gourl} Source0: %{gosource} # Generated by go-vendor-tools Source1: %{archivename}-vendor.tar.bz2 Source2: go-vendor-tools.toml BuildRequires: go-vendor-tools BuildRequires: git-core Requires: git-core %description A GitLab CLI tool bringing GitLab to your command line. %prep %goprep -A %setup -q -T -D -a1 %{forgesetupargs} %autopatch -p1 %generate_buildrequires %go_vendor_license_buildrequires -c %{S:2} %build export GO_LDFLAGS="-X main.version=%{version} \ -X main.buildDate=$(date -d "@${SOURCE_DATE_EPOCH}" +%Y-%m-%d) \ -X main.platform=Fedora -X main.debugMode=false" for cmd in cmd/glab cmd/gen-docs ; do %gobuild -o %{gobuilddir}/bin/$(basename $cmd) %{goipath}/$cmd done # Generate manpages %{gobuilddir}/bin/gen-docs --manpage --path ./share/man/man1 # Generate shell completions %{gobuilddir}/bin/%{name} completion -s bash > %{name}.bash %{gobuilddir}/bin/%{name} completion -s fish > %{name}.fish %{gobuilddir}/bin/%{name} completion -s zsh > %{name}.zsh %install # We are deliberately excluding cmd/gen-docs. It is only needed for building. install -Dpm 0755 %{gobuilddir}/bin/%{name} -t %{buildroot}%{_bindir}/ # Install manpages install -Dpm 0644 ./share/man/man1/%{name}*.1 -t %{buildroot}%{_mandir}/man1/ # Install shell completions install -Dpm 0644 %{name}.bash %{buildroot}%{bash_completions_dir}/%{name} install -Dpm 0644 %{name}.fish %{buildroot}%{fish_completions_dir}/%{name}.fish install -Dpm 0644 %{name}.zsh %{buildroot}%{zsh_completions_dir}/_%{name} # Install licenses %go_vendor_license_install -c %{S:2} %check %go_vendor_license_check -c %{S:2} %if %{with check} export NO_COLOR=1 git init git config --global --add safe.directory $(pwd) for test in "Test_printError" "TestAliasDelete" "Test_statusRun" \ "Test_statusRun_noHostnameSpecified" "Test_statusRun_noInstance" \ "TestNewCmdCompletion" "TestNewCheckUpdateCmd" "Test_deleteRun" \ "Test_setRun_project" "Test_setRun_group" "Test_updateRun_project" \ "Test_updateRun_group" "TestGetRemoteURL" "Test_isColorEnabled" \ "Test_makeColorFunc" "Test_HelperFunctions" "Test_StackRemoveBranch" \ "Test_updateMRs" "Test_LocalConfigDir" "Test_LocalConfigFile" \ "TestCIGetJSON" "TestCIGet" \ ; do awk -i inplace '/^func.*'"$test"'\(/ { print; print "\tt.Skip(\"disabled failing test\")"; next}1' $(grep -rl $test) done %gocheck -d gitlab.com/gitlab-org/cli/commands \ -d gitlab.com/gitlab-org/cli/commands/auth/login \ -d gitlab.com/gitlab-org/cli/commands/ci/lint \ -d gitlab.com/gitlab-org/cli/commands/ci/trace \ -d gitlab.com/gitlab-org/cli/commands/issuable/view \ -d gitlab.com/gitlab-org/cli/commands/issue/delete \ -d gitlab.com/gitlab-org/cli/commands/mr \ -d gitlab.com/gitlab-org/cli/commands/mr/delete \ -d gitlab.com/gitlab-org/cli/commands/mr/note \ -d gitlab.com/gitlab-org/cli/commands/mr/subscribe \ -d gitlab.com/gitlab-org/cli/commands/mr/unsubscribe \ -d gitlab.com/gitlab-org/cli/commands/mr/update \ -d gitlab.com/gitlab-org/cli/commands/mr/view \ -d gitlab.com/gitlab-org/cli/commands/project/archive \ -d gitlab.com/gitlab-org/cli/commands/project/clone \ -d gitlab.com/gitlab-org/cli/commands/project/create \ -d gitlab.com/gitlab-org/cli/commands/schedule/list \ -d gitlab.com/gitlab-org/cli/commands/schedule/run %endif %files -f %{go_vendor_license_filelist} %doc README.md %{_bindir}/glab %{_mandir}/man1/%{name}*1* %{bash_completions_dir}/%{name} %{fish_completions_dir}/%{name}.fish %{zsh_completions_dir}/_%{name} %changelog ## START: Generated by rpmautospec * Tue Jul 08 2025 Maxwell G - 1.61.0-1 - Update to 1.61.0. Use vendored deps. * Thu Jan 16 2025 Fedora Release Engineering - 1.50.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild * Thu Nov 28 2024 Packit - 1.50.0-1 - Update to 1.50.0 upstream release - Resolves: rhbz#2329351 * Fri Nov 15 2024 Packit - 1.49.0-1 - Update to 1.49.0 upstream release - Resolves: rhbz#2326391 * Thu Oct 17 2024 Packit - 1.48.0-1 - Update to 1.48.0 upstream release - Resolves: rhbz#2319407 * Wed Oct 02 2024 Packit - 1.47.0-1 - Update to 1.47.0 upstream release - Resolves: rhbz#2316205 * Tue Sep 10 2024 Packit - 1.46.1-1 - Update to 1.46.1 upstream release - Resolves: rhbz#2309743 * Wed Jul 31 2024 Packit - 1.45.0-1 - Update to 1.45.0 upstream release - Resolves: rhbz#2299322 * Thu Jul 18 2024 Fedora Release Engineering - 1.42.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild * Fri Jul 12 2024 Mikel Olasagasti Uranga - 1.42.0-1 - Update to 1.42.0 - Closes rhbz#2277027 * Wed May 01 2024 Mikel Olasagasti Uranga - 1.39.0-2 - Fix ci view * Thu Apr 18 2024 Mikel Olasagasti Uranga - 1.39.0-1 - Update to 1.39.0 - Closes rhbz#2275984 * Sat Apr 06 2024 Mikel Olasagasti Uranga - 1.38.0-1 - Update to 1.38.0 - Closes rhbz#2273800 * Thu Mar 07 2024 Mikel Olasagasti Uranga - 1.37.0-2 - Don't package devel * Thu Mar 07 2024 Mikel Olasagasti Uranga - 1.37.0-1 - Update to 1.37.0 - Closes rhbz#2268481 * Sun Feb 11 2024 Maxwell G - 1.36.0-4 - Rebuild for golang 1.22.0 * Wed Jan 24 2024 Fedora Release Engineering - 1.36.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Fri Jan 19 2024 Fedora Release Engineering - 1.36.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Wed Dec 13 2023 Mikel Olasagasti Uranga - 1.36.0-1 - Update to 1.36.0 - Closes rhbz#2254410 * Fri Nov 17 2023 Mikel Olasagasti Uranga - 1.35.0-1 - Update to 1.35.0 - Closes rhbz#2248170 * Tue Oct 24 2023 Mikel Olasagasti Uranga - 1.34.0-1 - Update to 1.34.0 - Closes rhbz#2245759 * Wed Aug 23 2023 Mikel Olasagasti Uranga - 1.32.0-1 - Update to 1.32.0 - Closes rhbz#2233224 * Wed Jul 19 2023 Fedora Release Engineering - 1.31.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild * Wed Jun 28 2023 Mikel Olasagasti Uranga - 1.31.0-1 - Update to 1.31.0 - Closes rhbz#2208685 * Sat May 20 2023 Mikel Olasagasti Uranga - 1.30.0-1 - Update to 1.30.0 - Closes rhbz#2208685 * Fri May 12 2023 Mikel Olasagasti Uranga - 1.29.4-1 - Update to 1.29.4 - Closes rhbz#2193211 * Fri Apr 21 2023 Mikel Olasagasti Uranga - 1.28.1-1 - Update to 1.28.1 - Closes rhbz#2186556 * Thu Apr 13 2023 Mikel Olasagasti Uranga - 1.28.0-1 - Update to 1.28.0 - Closes rhbz#2186556 * Thu Apr 13 2023 Mikel Olasagasti Uranga - 1.27.1-1 - Update to 1.27.1 - Closes rhbz#2184809 * Sat Apr 01 2023 Mikel Olasagasti Uranga - 1.27.0-1 - Update to 1.27.0 - Closes rhbz#2183570 * Sat Mar 11 2023 Fabio Valentini - 1.26.0-2 - Rebuild for https://pagure.io/releng/issue/11327 * Fri Mar 10 2023 Mikel Olasagasti Uranga - 1.26.0-1 - Update to 1.26.0 - Closes rhbz#2177308 * Thu Feb 09 2023 Mikel Olasagasti Uranga - 1.25.3-1 - Update to 1.25.3 * Wed Feb 08 2023 Mikel Olasagasti Uranga - 1.24.1-1 - Initial package - Closes rhbz#2159522 ## END: Generated by rpmautospec