Get more, or next stackoverflow answer.
See original GitHub issueuse case and feature request
-
I’m in my editor and I want instructions for root mean squared error in python, so I press my keystroke to package my selected string:
rmse
to the cht.sh servers like this:curl cht.sh/python/rmse?T
-
It responds with the selected answer from here: https://stackoverflow.com/questions/17197492/is-there-a-library-function-for-root-mean-square-error-rmse-in-python
-
That’s fine, now this selected answer is kind of trash (not your fault) and the next highest-upvoted but not-selected answer is great: https://stackoverflow.com/a/37861832/445131
-
Is there a way I can tell your server to: “Get N more stackoverflow answers on this page?” or “Get the next stackoverflow answer on this stackoverflow page”? I could even give you search term like the:
so/q/17197492
Attempting to solve my own problem my way, I saw: https://github.com/dbeniamine/cheat.sh-vim has a <leader>KAN Next Answer
keystroke, but that’s not the next stackoverflow answer, that’s the last/next query.
What I have to do now is take my hand off the keyboard and visit stackoverflow by that questionid, and then use the mouse to scroll down, which is doubleplusungood.
How would you do this so I can keep my fingers on home row; my right hand not taking the thousand-year journey to the GUI-land.
Issue Analytics
- State:
- Created 4 years ago
- Comments:9 (3 by maintainers)
Top GitHub Comments
@sentientmachine Eric, I think your solution is though good, but it would be much better, if we could get 50 (or 20) answers at once (as a JSON structure for example), so it would be possible to search through them. Of course, for that we need some additional support from the client (
cht.sh
or editor plugins side), but currently we do not have this functionality even on the server side.The best solution probably should be some combination of the “multiple answers” feature with the “client-side search” feature, so that we could just fetch a set of possible answers first (with some more or less general query) and then refine the search with additional keywords.
In the vim plugin, I think that the smoother approach would be to add both an optional parameter and an optional configuration variable:
So if you type:
It will ask for
g:CheatSheetNumAnswers
(1 in this case) answers, but you can quickly ask for:And get exactly 3 answers
I’ll implement that as soon as agree on what part should be done client side.
Does the other plugin that provides this functionality have rate limitation ?