Order the query results, to ensure that pagination works.
Left-pad the filenames with zeros, so that their lexicographic
sort order (as returned by ls) is also their pagination order.
How to test these changes?
I ran BUGOUT_ACCESS_TOKEN=XXX BUGOUT_JOURNAL_ID=YYY ./scripts/humbug.bash and observed the filenames being written, and that the content contained consistently ordered data.
Changes
How to test these changes?
I ran
BUGOUT_ACCESS_TOKEN=XXX BUGOUT_JOURNAL_ID=YYY ./scripts/humbug.bash
and observed the filenames being written, and that the content contained consistently ordered data.Related issues