I'm trying to get a auto completion for folders that I don't have permission to view / enter, my first thought was to use `compgen` and `sudo` to do the completion manually, but looks like `compgen` is a shell builtin, so launching it with sudo may not work.

Also, if I wrote customized completion function for folders, how can I overwrite for every command? I don't want to do `complete` command for everything.

Or is there any alternative ways?