Skip to content

#RI-3479 - update readme (add redis-auto button) #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Oct 21, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: false
automatic_release_tag: latest
automatic_release_tag: release
files: |
data.zip
build.json
65 changes: 64 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,10 @@ or relative path to image inside the [statics](https://github.com/RedisInsight/T

#### Redis Code block
![Redis Code block](docs/tutorials-redis-code-block.png)
A button that inserts Redis code into the Code Editor. The syntax is almost the same as for [Fenced Code Block](https://www.markdownguide.org/extended-syntax/#fenced-code-blocks), the only difference is that you must specify `redis` as language and the label next to it (`Create` in the example below).

###### Manual-execute button
A button that inserts Redis commands in the Editor. The syntax is almost the same as for the [Fenced Code Block](https://www.markdownguide.org/extended-syntax/#fenced-code-blocks),
the only difference is that you must specify `redis` as language and the label next to it (`Create` in the example below).
````
```redis Create
// Let's add three documents as Hashes.
Expand All @@ -123,6 +126,66 @@ A button that inserts Redis code into the Code Editor. The syntax is almost the

```
````

###### Auto-execute button
![img.png](docs/tutorials-redis-auto-code-block.png)

A button that automatically executes the Redis commands (without inserting it into the Editor). Such buttons will be displayed with the "Play" icon inside.
The code syntax is the same as for the manually executed buttons, just indicate the `redis-auto` (instead of `redis`) before the button.

````
```redis-auto Create
// Let's add three documents as Hashes.
// Each document represents a building permit.

HSET permit:1 "description" "To reconstruct a single detached house with a front covered veranda." "construction_value" 42000 "building_type" "single detached house" "address_city" "Lisbon" "work_type" "demolition,reconstruction" "permit_timestamp" "1602156878" "address_street" "R. Da Palma" "location" "38.717746, -9.135839"

HSET permit:2 "description" "To construct a loft" "construction_value" 53000 "building_type" "apartment" "address_city" "Porto" "work_type" "construction" "permit_timestamp" "1556546400" "address_street" "Rua da Boavista" "location" "41.155854, -8.616721"

HSET permit:3 "description" "New house build" "construction_value" 260000 "building_type" "house" "address_city" "Lagos" "work_type" "construction;design" "permit_timestamp" "1612947600" "address_street" "R. Antonio Gedeao" "location" "37.114864, -8.668521"

```
````

###### Auto-execute button parameters

You can customize the run parameters to configure the raw mode, pipeline parameter and group mode. If specified, they will override
the configuration set in RedisInsight. If not specified - the behaviour will be defined by parameters set in RedisInsight.
To specify the parameters, insert them after the `redis-auto:` and add the parameters in square brackets separated with a semicolon (`;`) in
the following way:

```
redis-auto:[<parameter1>;<parameter2>;<...>;<parameterN>]
```

Ensure that all the parameters are listed **without spaces**, ordering does not matter.

_Supported parameters:_

| Name | Values | Notes | Description |
|----------|--------------------------|-------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------|
| results | * _single_<br/>* _group_ | If enabled, then pipeline mode is ignored | Enable/disable the group mode to display the command results in a batch or as separate ones. |
| mode | * _ascii_<br/>* _raw_ | | Enable/disable the raw mode to display command results. |
| pipeline | any integer number | | Configure the number of commands in the pipeline. 0 or 1 pipelines every command. |


_Notes:_

* Ensure that there are no spaces
* All the parameters with mistakes will be ignored

_Examples:_

```
redis-auto:[results=single]
redis-auto:[mode=raw]
redis-auto:[pipeline=1]
redis-auto:[results=single;mode=raw]
redis-auto:[results=single;pipeline=4]
redis-auto:[results=group;mode=ascii]
redis-auto:[pipeline=8;mode=raw;results=single;]
```

## Autoupdate
Our application supports the ability to quickly update the static files of the Enablement area so that we can provide users with up-to-date information.

Expand Down
Binary file added docs/tutorials-redis-auto-code-block.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.