1
0
mirror of https://github.com/l1ving/youtube-dl synced 2026-05-30 13:31:05 +08:00

Install bash completion into share/bash-completion/completions

Starting with bash-completion 1.90 (released in November 2011) completion files should be installed in the share/ directory.

They must use the executable’s name for loading on demand, so for this reason, it was necessary to generate the completion file in a new directory, so that it does not clash with the `youtube-dl` executable.

This is because Python’s setup-tools does not support data files to be installed with a different base name.

I have tested this change with both `make install` and `pip install`, as these two install procedures have slightly different code paths.

I removed the `bash-completion` (phony) target from the make file, as we now have a directory with that name, and I could not see the target being referenced anywhere.

Closes #804.
This commit is contained in:
Allan Odgaard
2019-09-10 10:53:34 +02:00
Unverified
parent bff90fc518
commit 7a4e8d91d2
5 changed files with 15 additions and 16 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ import sys
sys.path.insert(0, dirn(dirn((os.path.abspath(__file__)))))
import youtube_dl
BASH_COMPLETION_FILE = "youtube-dl.bash-completion"
BASH_COMPLETION_FILE = "bash-completion/youtube-dl"
BASH_COMPLETION_TEMPLATE = "devscripts/bash-completion.in"