That's a different idea. Are you proposing to provide URLs if this psql
variable is set and it doesn't find an entry (say \h foo)? I'm not sure if it
is a good idea to allow third-party URLs (even if it is configurable).
If you want to check the patch Andrey published. We basically set the default value to the set variable, and then allowed the user to override that value with multiple pipe (|) separated URLs. It does BEG the question if this is cool for hackers. Personally, I like the option as there are probably a few resources worth checking against. But if someone doesn't change the default, they get a good enough answer.
IMO we should expand \h to list documentation references for functions and GUCs
using SGML files. We already did it for SQL commands. Another broader idea is
to build an inverted index similar to what Index [1] provides. The main problem
with this approach is to create a dependency between documentation build and
psql. Maybe there is a reasonable way to obtain the links for each term.
I don't want to add more dependencies into psql to the documentation for a ton of stuff. To me, if we had a better search page on the website for finding things, it would be great. I have been resigned to just googling "postgresql <topic>" because google does a better job searching postgresql.org than the postgresql.org site does (even when it is a known indexed item like a function name).