Sort docs by version, with latest at the top
Summary:
This patch fixes two issues:
- The latest version is not the first thing users see on the docs index.
- The sorting is broken. This issue will not become evident until 0.22.10, but it will be very broken once we get there without this patch.
Test Plan:
In order to verify the sorting is correct, you will need to generate some bogus
docs by copying the existing ones and replacing version numbers, for example:
cp -r 0.22.1 0.22.10 find "0.22.10" -type f -print0 | xargs -0 sed -i 's/0.22.1/0.22.10/g'
make serve
Navigate to http://127.0.0.1:4000/doc/
Verify the order is correct (latest to oldest) and sorting is correct (0.22.10 comes after 0.22.1).
Reviewers: #bitcoin_abc, deadalnix
Reviewed By: #bitcoin_abc, deadalnix
Differential Revision: https://reviews.bitcoinabc.org/D7456