bugzilla-daemon at netfilter.org
2020-Jul-16 23:00 UTC
[Bug 1443] New: ipset -bash: syntax error near unexpected token `;;'
https://bugzilla.netfilter.org/show_bug.cgi?id=1443 Bug ID: 1443 Summary: ipset -bash: syntax error near unexpected token `;;' Product: ipset Version: unspecified Hardware: x86_64 OS: other Status: NEW Severity: minor Priority: P5 Component: default Assignee: netfilter-buglog at lists.netfilter.org Reporter: vrein at tuta.io - ipset version: ipset v7.6, protocol version: 7 - system: arch linux - latest git repo has the same code too There is an additional ; in bash completion script: grep '_ipset_known_hosts()' -n ./ -R ./utils/ipset_bash_completion/ipset:975:eval '_ipset_known_hosts() { '$(declare -f _known_hosts_real | grep -v __ltrim_colon_completions | grep -Ev "^_known_hosts_real.*$" | grep -Ev "^(\{|\})")'; }' ^ - here Fist semicolon gets into from declare -f _known_hosts_real | grep -v __ltrim_colon_completions | grep -Ev "^_known_hosts_real.*$" | grep -Ev "^(\{|\})" pipeline, and on 975 line there is second. Arch Linux latest: declare -f _known_hosts_real | grep -v __ltrim_colon_completions | grep -Ev "^_known_hosts_real.*$" | grep -Ev "^(\{|\})" | tail -n 5 for i in "${!COMPREPLY[@]}"; do [[ -n ${COMPREPLY[i]} ]] || unset -v COMPREPLY[i]; done; fi; Also can reproduce this on Ubuntu 18.04: declare -f _known_hosts_real | grep -v __ltrim_colon_completions | grep -Ev "^_known_hosts_real.*$" | grep -Ev "^(\{|\})" | tail -n 5 for i in ${!COMPREPLY[@]}; do [[ -n ${COMPREPLY[i]} ]] || unset -v COMPREPLY[i]; done; fi; And on Ubuntu 20.04 additional semicolon (975 line) are already removed. Ubuntu 16.04 return a little bit different result, so completion works without errors. declare -f _known_hosts_real | grep -v __ltrim_colon_completions | grep -Ev "^_known_hosts_real.*$" | grep -Ev "^(\{|\})" | tail -n 5 COMPREPLY+=($( compgen -W "$( ruptime 2>/dev/null | awk '!/^ruptime:/ { print $1 }' )" -- "$cur" )); if [[ -n ${COMP_KNOWN_HOSTS_WITH_HOSTFILE-1} ]]; then COMPREPLY+=($( compgen -A hostname -P "$prefix$user" -S "$suffix" -- "$cur" )); fi; return 0 I understand that this is may not be scope of ipset developers, so should I direct this issue to distro maintainers? -- You are receiving this mail because: You are watching all bug changes. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.netfilter.org/pipermail/netfilter-buglog/attachments/20200716/9fda6d7d/attachment.html>
bugzilla-daemon at netfilter.org
2021-Jan-19 07:58 UTC
[Bug 1443] ipset -bash: syntax error near unexpected token `;;'
https://bugzilla.netfilter.org/show_bug.cgi?id=1443 Jozsef Kadlecsik <kadlec at netfilter.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kadlec at netfilter.org --- Comment #1 from Jozsef Kadlecsik <kadlec at netfilter.org> --- The bash completion script is not developed by me, so the best is to report the bug at https://github.com/AllKind/ipset-bash-completion That way it'll be fixed at every distro which uses the ipset bash completion. Jozsef -- You are receiving this mail because: You are watching all bug changes. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.netfilter.org/pipermail/netfilter-buglog/attachments/20210119/5a82415f/attachment.html>
Apparently Analagous Threads
- [PATCH 5/5] bash completion: Add missing bash completion scripts (RHBZ#1367738).
- [PATCH] bash: Add a bash completion script for virt-v2v-copy-to-local (RHBZ#1367738).
- [PATCH] bash: Implement tab completion for virt-win-reg (RHBZ#1367738).
- [p2v PATCH] Add bash completion scripts
- [PATCH 1/2] resize: add --unknown-filesystems