Please describe the feature you’d like to see added.
When building a package, I currently have the following code to include shell completions for the relevant components:
0for tool in bitcoin bitcoin-tx bitcoin-util bitcoin-wallet bitcoin-chainstate libbitcoinkernel
1do
2 DESTDIR="$pkgdir" cmake --install build --component "$tool"
3
4 # shell completions
5 if [ -f "contrib/completions/bash/$tool.bash" ]; then
6 install -Dm644 "contrib/completions/bash/$tool.bash" \
7 "$pkgdir/usr/share/bash-completion/completions/$tool"
8 fi
9 if [ -f "contrib/completions/fish/$tool.fish" ]; then
10 install -Dm644 contrib/completions/fish/$tool.fish \
11 -t "$pkgdir/usr/share/fish/vendor_completions.d/"
12 fi
13done
Is your feature related to a problem, if so please describe it.
No response
Describe the solution you’d like
I’m wondering if there could be a way to include the shell completions in cmake --install, so running DESTDIR="$pkgdir" cmake --install build --component bitcoin-tx would copy shell completions to DESTDIR, if any are available.
Describe any alternatives you’ve considered
Keeping the current code as-is. :)
Please leave any additional context
No response