aitjcize / cppman

C++ 98/11/14 manual pages for Linux/MacOS
GNU General Public License v3.0
1.27k stars 79 forks source link

fix "too many values to unpack" with --cache-all #77

Closed mkmkme closed 6 years ago

mkmkme commented 6 years ago

It seems like cplusplus.com changed API a little bit. Now data comes with tag as the third argument in tuple:

('std::fstream::swap (fstream)', 'http://www.cplusplus.com/reference/fstream/fstream/swap/', 'C++11')

Tag can be empty string. But --cache-all is broken now:

λ cppman --cache-all
By default, cppman fetches pages on-the-fly if corresponding page is not found in the cache. The "cache-all" option is only useful if you want to view man pages offline. Caching all contents will take several minutes, do you want to continue [y/N]? y
Caching manpages from cplusplus.com ...
error: too many values to unpack (expected 2)

This commit just fixes --cache-all ignoring third argument

aitjcize commented 6 years ago

lgtm, thanks.