Skip to content

Commit f260fa8

Browse files
committed
style: remove function end comments
These are being used inconsistently here and there, and I don't think there's a need for them in the first place.
1 parent 4605edf commit f260fa8

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

bash_completion

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -826,7 +826,7 @@ _comp__reassemble_words()
826826
printf -v "$2[i]" %s "${COMP_WORDS[i]}"
827827
done
828828
fi
829-
} # _comp__reassemble_words()
829+
}
830830

831831
# @param $1 exclude Characters out of $COMP_WORDBREAKS which should NOT be
832832
# considered word breaks. This is useful for things like scp where
@@ -1013,7 +1013,7 @@ _comp_ltrim_colon_completions()
10131013
{
10141014
((${#COMPREPLY[@]})) || return 0
10151015
_comp_compgen -c "$1" ltrim_colon "${COMPREPLY[@]}"
1016-
} # _comp_ltrim_colon_completions()
1016+
}
10171017

10181018
# This function quotes the argument in a way so that readline dequoting
10191019
# results in the original argument. This is necessary for at least
@@ -1050,7 +1050,7 @@ _comp_quote_compgen()
10501050
printf -v ret "$value" # Decode escape sequences of \....
10511051
fi
10521052
fi
1053-
} # _comp_quote_compgen()
1053+
}
10541054

10551055
# This function performs file and directory completion. It's better than
10561056
# simply using 'compgen -f', because it honours spaces in filenames.
@@ -1112,7 +1112,7 @@ _comp_compgen_filedir()
11121112
# ${v+"${a[@]}"} when IFS does not contain whitespace.
11131113
local IFS=$' \t\n'
11141114
_comp_compgen -U toks set ${toks[@]+"${toks[@]}"}
1115-
} # _comp_compgen_filedir()
1115+
}
11161116

11171117
# This function splits $cur=--foo=bar into $prev=--foo, $cur=bar, making it
11181118
# easier to support both "--foo bar" and "--foo=bar" style completions.
@@ -2380,7 +2380,7 @@ _known_hosts()
23802380
[[ ${1-} == -c || ${2-} == -c ]] && options+=(-c)
23812381
local IFS=$' \t\n' # Workaround for connected ${v+"$@"} in bash < 4.4
23822382
_comp_compgen_known_hosts ${options[@]+"${options[@]}"} -- "$cur"
2383-
} # _known_hosts()
2383+
}
23842384

23852385
# Helper function to locate ssh included files in configs
23862386
# This function looks for the "Include" keyword in ssh config files and
@@ -2434,7 +2434,7 @@ _comp__included_ssh_config_files()
24342434
fi
24352435
done
24362436
done
2437-
} # _comp__included_ssh_config_files()
2437+
}
24382438

24392439
# Helper function for completing _known_hosts.
24402440
# This function performs host completion based on ssh's config and known_hosts
@@ -2658,7 +2658,7 @@ _comp_compgen_known_hosts__impl()
26582658
((${#known_hosts[@]})) || return 1
26592659

26602660
_comp_compgen -v known_hosts -c "$prefix$cur" ltrim_colon "${known_hosts[@]}"
2661-
} # _comp_compgen_known_hosts__impl()
2661+
}
26622662
complete -F _known_hosts traceroute traceroute6 \
26632663
fping fping6 telnet rsh rlogin ftp dig drill mtr ssh-installkeys showmount
26642664

bash_completion.d/000_bash_completion_compat.bash

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ quote_readline()
6464
local ret
6565
_comp_quote_compgen "$1"
6666
printf %s "$ret"
67-
} # quote_readline()
67+
}
6868

6969
# This function is the same as `_comp_quote_compgen`, but receives the second
7070
# argument specifying the variable name to store the result.
@@ -173,7 +173,7 @@ _get_cword()
173173
printf "%s" "${cur:0:index}"
174174
fi
175175
fi
176-
} # _get_cword()
176+
}
177177

178178
# Get word previous to the current word.
179179
# This is a good alternative to `prev=${COMP_WORDS[COMP_CWORD-1]}' because bash4
@@ -382,7 +382,7 @@ __expand_tilde_by_ref()
382382
_comp_expand_tilde "${!1-}"
383383
# shellcheck disable=SC2059
384384
[[ $1 == ret ]] || printf -v "$1" "$ret"
385-
} # __expand_tilde_by_ref()
385+
}
386386

387387
# @deprecated 2.12 Use `_comp_compgen -a cd_devices`
388388
_cd_devices()

0 commit comments

Comments
 (0)