algolia / cli

🔍 Algolia’s official CLI devtool
https://www.algolia.com/doc/tools/cli
MIT License
103 stars 26 forks source link

fix: descriptions #156

Closed kai687 closed 5 months ago

kai687 commented 5 months ago

Extract the first sentence of the parameter description and uses it as help text.

I wrote the specs such that the first sentence is followed by an empty line, followed by more information. For the CLI, we can extract the first sentence and use it as help text.

I replace any Markdown links [link text](https://some/url) with link text, so that it reads nicely in the terminal.

What do you think @clemfromspace ?

clemfromspace commented 5 months ago

Looks good, thanks @kai687! I do not see any links in the generated flags anymore though, is that intended?

kai687 commented 5 months ago

Good question! The links depend on the pages in the docs being there. Currently there are no pages for semanticSearch, reRankingApplyFilter, or cursor, so these links don't work.

I thought it would be too much of a dependency. Like, the flags themselves are coming from the specs and the links depend on the old docs. If we ever want to change that, we need to update the CLI as well.

For now, I could add back links to pages that exist. WDYT?

clemfromspace commented 5 months ago

@kai687 That sounds good 👍

kai687 commented 5 months ago

Thanks! Can't merge myself.