question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Provide an option to paginate through all pages

See original GitHub issue

Provide an option to paginate through all pages.

An option like --all-pages would be helpful and prevent workflows like this:

(
linode-cli --text kernels list --page=100
for p in {1..3}; do
  linode-cli --no-headers --text  kernels list --page $p
done
)

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:2
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
Dorthucommented, May 19, 2022

Instead of changing how the API includes pagination metadata or how the CLI interprets the spec, how about a built-in plugin that handles pagination for you?

linode-cli paginate linodes list 

A command like that might return all pages in the linodes list collection, requesting them in order and printing them in sequence. All normal CLI arguments could be accepted (and would be forwarded to the CLI when fetching pages), which should allow normal use of output format, filters, etc. If the action invoked this way isn’t a paginated action, it’s just handled normally with no error produced.

1reaction
lattwoodcommented, May 19, 2022

Handling pagination makes for an unweildy shell script. Additionally, there’s no pagination indicators when using the linode-cli with json.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Extract multiple pages through pagination - Tutorial - Octoparse
Extract multiple pages through pagination · Click on the pagination loop · Click on the "Click to paginate" action · Observe if the...
Read more >
Control pagination - Microsoft Support
Click the table. · On the Table menu, click Table Properties, and then click the Row tab. · Clear the Allow row to...
Read more >
Pagination Best Practices for Google | Documentation
However, pages in a paginated sequence don't need to follow this recommendation. You can use the same titles and descriptions for all pages...
Read more >
Pagination in the REST API - Atlassian Developer
For example, you might need to request all pages in the Demonstration space (ds is the spaceKey) of your Confluence instance, but you...
Read more >
Using AWS CLI pagination options
When using a command, by default the AWS CLI automatically makes multiple calls to return all possible results to create pagination. One call...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found