Skip to content

Commit 41f8711

Browse files
Restore back influx-cli-bash-completion subpackage and remove it from bash-completion (#12914)
1 parent 20acb09 commit 41f8711

2 files changed

Lines changed: 32 additions & 5 deletions

File tree

SPECS/bash-completion/bash-completion.spec

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Name: bash-completion
22
Version: 2.11
3-
Release: 1%{?dist}
3+
Release: 2%{?dist}
44
Summary: Programmable completion for bash
55
Group: Applications/Shells
66
Vendor: Microsoft Corporation
@@ -51,6 +51,9 @@ rm -f %{buildroot}%{_datadir}/bash-completion/completions/nmcli
5151
rm -f %{buildroot}%{_datadir}/bash-completion/completions/\
5252
{cal,chsh,dmesg,eject,hexdump,ionice,hwclock,ionice,look,mount,renice,rtcwake,su,umount}
5353

54+
# does not work anymore with new versions of influx and provided by influx-cli-bash-completion
55+
rm -f %{buildroot}%{_datadir}/bash-completion/completions/influx
56+
5457
%files
5558
%defattr(-,root,root)
5659
%license COPYING
@@ -60,7 +63,7 @@ rm -f %{buildroot}%{_datadir}/bash-completion/completions/\
6063
%dir %{_datadir}/bash-completion/helpers
6164
%{_datadir}/bash-completion/helpers/perl
6265
%{_datadir}/bash-completion/helpers/python
63-
%doc AUTHORS COPYING
66+
%doc AUTHORS
6467

6568
%files devel
6669
%defattr(-,root,root)
@@ -69,13 +72,17 @@ rm -f %{buildroot}%{_datadir}/bash-completion/completions/\
6972
%{_datadir}/pkgconfig/bash-completion.pc
7073

7174
%changelog
75+
* Wed Mar 12 2025 Mykhailo Bykhovtsev <mbykhovtsev@microsoft.com> - 2.11-2
76+
- Remove influx bash completion file as it no longer works and is provided by influx-cli-bash-completion package.
77+
- Removed duplicated license file
78+
7279
* Mon Jan 10 2022 Nicolas Guibourge <nicolasg@microsoft.com> - 2.11-1
7380
- Upgrade to 2.11.
7481

7582
* Thu Dec 16 2021 Pawel Winogrodzki <pawelwi@microsoft.com> - 2.7-5
7683
- Removing the explicit %%clean stage.
7784

78-
* Wed Oct 27 2021 Muhammad Falak <mwani@microsft.com> - 2.7-4
85+
* Wed Oct 27 2021 Muhammad Falak <mwani@microsoft.com> - 2.7-4
7986
- Remove epoch
8087

8188
* Mon Mar 08 2021 Thomas Crain <thcrain@microsoft.com> - 2.7-3

SPECS/influx-cli/influx-cli.spec

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
Summary: CLI for managing resources in InfluxDB
1919
Name: influx-cli
2020
Version: 2.7.5
21-
Release: 1%{?dist}
21+
Release: 2%{?dist}
2222
License: MIT
2323
Vendor: Microsoft Corporation
2424
Distribution: Azure Linux
@@ -46,6 +46,17 @@ BuildRequires: systemd-rpm-macros
4646
%description
4747
CLI for managing resources in InfluxDB v2.
4848

49+
%package bash-completion
50+
Summary: Bash Completion for %{name}
51+
Group: Productivity/Databases/Servers
52+
Requires: bash-completion
53+
Supplements: (%{name} and bash-completion)
54+
BuildArch: noarch
55+
56+
%description bash-completion
57+
The official bash completion script for influx. It includes support
58+
for every argument that can currently be passed to influx.
59+
4960
%package zsh-completion
5061
Summary: ZSH Completion for %{name}
5162
Group: Productivity/Databases/Servers
@@ -69,6 +80,9 @@ go build -mod vendor -ldflags="-X main.version=%{version}" -o bin/influx ./cmd/i
6980
mkdir -p %{buildroot}%{_bindir}
7081
install -D -m 0755 bin/influx %{buildroot}%{_bindir}/
7182

83+
mkdir -p %{buildroot}/%{_datadir}/bash-completion/completions
84+
bin/influx completion bash > %{buildroot}/%{_datadir}/bash-completion/completions/influx
85+
7286
mkdir -p %{buildroot}/%{_datadir}/zsh/site-functions
7387
bin/influx completion zsh > %{buildroot}/%{_datadir}/zsh/site-functions/_influx
7488

@@ -77,10 +91,16 @@ bin/influx completion zsh > %{buildroot}/%{_datadir}/zsh/site-functions/_influx
7791
%doc README.md CHANGELOG.md
7892
%{_bindir}/influx
7993

94+
%files bash-completion
95+
%{_datadir}/bash-completion
96+
8097
%files zsh-completion
8198
%{_datadir}/zsh
8299

83100
%changelog
101+
* Wed Mar 12 2025 Mykhailo Bykhovtsev <mbykhovtsev@microsoft.com> - 2.7.5-2
102+
- Add back bash-completion subpackage for influx-cli
103+
84104
* Tue Feb 11 2025 CBL-Mariner Servicing Account <cblmargh@microsoft.com> - 2.7.5-1
85105
- Auto-upgrade to 2.7.5 - Update influx-cli to match influxdb version for CVE-2023-44487
86106

@@ -105,7 +125,7 @@ bin/influx completion zsh > %{buildroot}/%{_datadir}/zsh/site-functions/_influx
105125
* Thu Jun 15 2023 CBL-Mariner Servicing Account <cblmargh@microsoft.com> - 2.6.1-9
106126
- Bump release to rebuild with go 1.19.10
107127

108-
* Thu May 25 2023 Mykhailo Bykhovtsev <mbykhovtsev@microsft.com> - 2.6.1-8
128+
* Thu May 25 2023 Mykhailo Bykhovtsev <mbykhovtsev@microsoft.com> - 2.6.1-8
109129
- Removed bash-completion subpackage since the script produced is included in original bash-completion.
110130

111131
* Wed Apr 05 2023 CBL-Mariner Servicing Account <cblmargh@microsoft.com> - 2.6.1-7

0 commit comments

Comments
 (0)