Skip to content

Commit

Permalink
feat(wget): ipv6 addresses for --bind-address
Browse files Browse the repository at this point in the history
Fixes #1315
  • Loading branch information
yedayak committed Jan 20, 2025
1 parent 0ea21b9 commit d3ff6a7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 2 additions & 2 deletions completions/wget
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
_comp_cmd_wget()
{
local cur prev words cword was_split comp_args
_comp_initialize -s -- "$@" || return
_comp_initialize -s -n : -- "$@" || return

local noargopts='!(-*|*[DPoaOitTwlQeBUARIX]*)'
# shellcheck disable=SC2254
Expand All @@ -16,7 +16,7 @@ _comp_cmd_wget()
return
;;
--bind-address)
_comp_compgen_ip_addresses
_comp_compgen_ip_addresses -a
return
;;
--domains | --exclude-domains | -${noargopts}D)
Expand Down
5 changes: 5 additions & 0 deletions test/t/test_wget.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,8 @@ def test_1(self, completion):
@pytest.mark.complete("wget --s", require_cmd=True)
def test_2(self, completion):
assert completion

@pytest.mark.complete("wget --bind-address=:")
def test_3(self, completion):
# Binding to ipv6 localhost
assert ":1" in completion

0 comments on commit d3ff6a7

Please sign in to comment.