@@ -176,18 +176,22 @@ A. [ Disclaimer: Here, how to make the completion code visible to
176176 Install it in one of the directories pointed to by bash-completion's
177177 ` pkgconfig ` file variables. There are two alternatives:
178178
179- - The recommended directory is ` completionsdir ` , which you can get with
179+ - The recommended directory is ` < completionsdir> ` , which you can get with
180180 ` pkg-config --variable=completionsdir bash-completion ` . From this
181181 directory, completions are automatically loaded on demand based on invoked
182182 commands' names, so be sure to name your completion file accordingly, and
183183 to include (for example) symbolic links in case the file provides
184- completions for more than one command. The completion filename for
185- command ` foo ` in this directory should be either ` foo ` , or ` foo.bash ` .
186- (Underscore prefixed ` _foo ` works too, but is reserved for
187- bash-completion internal use as a deprecation/fallback marker.)
188- - The other directory which is only present for backwards compatibility,
189- its usage is no longer recommended, is ` compatdir ` (get it with
190- ` pkg-config --variable=compatdir bash-completion ` ). From this
184+ completions for more than one command. The completion filename for command
185+ ` foo ` in this directory should be ` foo.bash ` . Unsuffixed ` foo ` also
186+ works, but it is deprecated in >= 2.18.
187+ - Helper scripts used by completions may be placed in the directory
188+ ` <helpersdir> ` , which can be retrieved with `pkg-config
189+ --variable=helpersdir bash-completion`. The completion files in
190+ ` <completionsdir> ` can reference the helper script ` <helpersdir>/<helper> `
191+ as ` ${BASH_SOURCE[0]%/*}/../helpers/<helper> ` .
192+ - The other directory, which is only present for backwards compatibility and
193+ is not recommended to use, is ` <compatdir> ` (get it with
194+ ` pkg-config --variable=compatdir bash-completion ` ). From this
191195 directory, files are loaded eagerly when ` bash_completion ` is loaded.
192196
193197 For packages using GNU autotools the installation can be handled
0 commit comments