1
0
Fork
You've already forked redict-doc
0
forked from redict/redict-doc
Documentation for Redict
Makefile 100%
Find a file
Drew DeVault 6f10cf654a modules: drop non-free modules from listing
Signed-off-by: Drew DeVault <sir@cmpwn.com>
2024年03月24日 15:27:25 +01:00
.github/workflows Spellchecker action ( #1980 ) 2022年06月06日 15:24:25 +03:00
clients Add client Redis::Cluster::Fast for Perl ( #2664 ) 2024年03月13日 09:05:46 +01:00
commands commands: s/Redis/Redict/g 2024年03月24日 12:05:35 +01:00
community Changes in the context of the Redis license change 2024年03月20日 23:54:23 +02:00
docs Changes in the context of the Redis license change 2024年03月20日 23:54:23 +02:00
libraries Add librdb tool and c-library ( #2675 ) 2024年02月28日 16:57:32 +02:00
modules/community/github.com modules: drop non-free modules from listing 2024年03月24日 15:27:25 +01:00
resources DOC-2511: reorder the clients by language list 2023年07月27日 11:35:20 -07:00
tools Add librdb tool and c-library ( #2675 ) 2024年02月28日 16:57:32 +02:00
.gitignore Docs reorg ( #2419 ) 2023年07月05日 15:25:21 +03:00
.spellcheck.yml Moves community projects to resources ( #2187 ) 2022年11月03日 21:43:43 +02:00
_index.md Organizes data 2022年03月19日 20:44:00 +02:00
commands.json Pull commands.json from Redict 2024年03月24日 12:23:49 +01:00
COPYRIGHT License URL fixed. 2014年04月16日 16:00:45 +02:00
groups.json adds groups.json 2022年03月14日 15:15:07 +02:00
languages.json Add Ballerina to the list of languages ( #2684 ) 2024年03月12日 09:19:17 +01:00
LICENSE Create LICENSE 2019年10月27日 21:57:32 +02:00
Makefile Merge modules into one modules.json file 2024年03月24日 14:22:39 +01:00
modules.json modules: drop non-free modules from listing 2024年03月24日 15:27:25 +01:00
README.md Initial cleanup of top-level items 2024年03月23日 11:32:30 +01:00
resp2_replies.json Fix the rendering of the RESP documentation for the INFO command ( #2676 ) 2024年03月07日 13:22:23 +01:00
resp3_replies.json Fix the rendering of the RESP documentation for the INFO command ( #2676 ) 2024年03月07日 13:22:23 +01:00
tool_types.json Add tools category 'Other' with K8s related tools ( #2300 ) 2023年01月26日 23:57:03 +01:00
wordlist Improve RDB to AOF conversion docs ( #2521 ) 2023年12月19日 13:45:53 +01:00

Redict documentation

Clients

All clients are listed under language specific sub-folders of clients

The path follows the pattern: clients/{language}/github.com/{owner}/{repository}.json. The {language} component of the path is the path-safe representation of the full language name which is mapped in languages.json.

Commands

Redict commands are described in the commands.json file that is auto generated from the Redict repo based on the JSON files in the commands folder.

See: https://codeberg.org/redict/redict/src/branch/unstable/src/commands

For each command there's a Markdown file with a complete, human-readable description. We process this Markdown to provide a better experience, so some things to take into account:

  • Inside text, all commands should be written in all caps, in between backticks. For example: INCR.

  • You can use some magic keywords to name common elements in Redict. For example: @multi-bulk-reply. These keywords will get expanded and auto-linked to relevant parts of the documentation.

Each command will have a description and both RESP2 and RESP3 return values. Regarding the return values, these are contained in the files:

  • resp2_replies.json
  • resp3_replies.json

Each file is a dictionary with a matching set of keys. Each key is an array of strings that, when processed, produce Markdown content. Here's an example:

{
 ...
 "ACL CAT": [
 "One of the following:",
 "* [Array reply](/docs/reference/protocol-spec#arrays): an array of [Bulk string reply](/docs/reference/protocol-spec#bulk-strings) elements representing ACL categories or commands in a given category.",
 "* [Simple error reply](/docs/reference/protocol-spec#simple-errors): the command returns an error if an invalid category name is given."
 ],
 ...
}

Important: when adding or editing return values, be sure to edit both files. Use the following links for the reply type. Note: do not use @reply-type specifiers; use only the Markdown link.

@simple-string-reply: [Simple string reply](https://redict.io/docs/reference/protocol-spec#simple-strings)
@simple-error-reply: [Simple error reply](https://redict.io/docs/reference/protocol-spec#simple-errors)
@integer-reply: [Integer reply](https://redict.io/docs/reference/protocol-spec#integers)
@bulk-string-reply: [Bulk string reply](https://redict.io/docs/reference/protocol-spec#bulk-strings)
@array-reply: [Array reply](https://redict.io/docs/reference/protocol-spec#arrays)
@nil-reply: [Nil reply](https://redict.io/docs/reference/protocol-spec#bulk-strings)
@null-reply: [Null reply](https://redict.io/docs/reference/protocol-spec#nulls)
@boolean-reply: [Boolean reply](https://redict.io/docs/reference/protocol-spec#booleans)
@double-reply: [Double reply](https://redict.io/docs/reference/protocol-spec#doubles)
@big-number-reply: [Big number reply](https://redict.io/docs/reference/protocol-spec#big-numbers)
@bulk-error-reply: [Bulk error reply](https://redict.io/docs/reference/protocol-spec#bulk-errors)
@verbatim-string-reply: [Verbatim string reply](https://redict.io/docs/reference/protocol-spec#verbatim-strings)
@map-reply: [Map reply](https://redict.io/docs/reference/protocol-spec#maps)
@set-reply: [Set reply](https://redict.io/docs/reference/protocol-spec#sets)
@push-reply: [Push reply](https://redict.io/docs/reference/protocol-spec#pushes)

Styling guidelines

Please use the following formatting rules (aiming for smaller diffs that are easier to review):

  • No need for manual lines wrapping at any specific length, doing so usually means that adding a word creates a cascade effect and changes other lines.
  • Please avoid writing lines that are too long, this makes the diff harder to review when only one word is changed.
  • Start every sentence on a new line.

Checking your work

After making changes to the documentation, you can use the spellchecker-cli package to validate your spelling as well as some minor grammatical errors. You can install the spellchecker locally by running:

npm install --global spellchecker-cli

You can than validate your spelling by running the following

spellchecker --no-suggestions -f '**/*.md' -l en-US -q -d wordlist

Any exceptions you need for spelling can be added to the wordlist file.