I'm building a resource that references man pages, and I'm wondering if anyone knows of a way to access man pages as structured data? My current approach is to do a lot if REGEXing, but this is tedious and prone to errors.
I'm not an expert on *nix, but what I understand about man pages is that they are basically text files with a particular syntax that is parsable by the man command. This makes me a little skeptical that there might be an easy way to, say, access a list of the options or flags. But maybe there's a way to do it that I don't know.