The emerge completion used in bash-completion should be able to use any PORTAGE_OVERLAY that might be set to find packages instead of only /usr/portage. Reproducible: Always Steps to Reproduce: 1. Install bash-completion. 2. Create a PORTAGE_OVERLAY with a new ebuild in it. 3. Try to use emerge completion to get the new package. Actual Results: bash-completion will only list packages in /usr/portage. Expected Results: bash-completion will list all packages matching in /usr/portage as well as PORTAGE_OVERLAY.
That's a feature request which should be addressed to the author of the "gentoo"-completion. It's not something i can fix. I'm not the author of that script. I also think it makes it even slower if it has to scan both. It also uses everything hardcoded on /usr/portage and not what you set in make.conf because of speed reasons. The design requets that it scans realtime on each "tab". If you need application features please send them to the author of the script.
The reasons Christian stated for not using PORTAGE_OVERLAY are correct. Tab completion should, in my opinion, be as fast as possible. Adding another directory tree to scan would most likely slow things down too much. At this point, I don't have any plans to add this to the completion code. Sorry.
Won't be fixed because of performance reasons. (See comment from the author)