FarNet.Redis 0.7.1

The ID prefix of this package has been reserved for one of the owners of this package by NuGet.org. Prefix Reserved
dotnet add package FarNet.Redis --version 0.7.1
NuGet\Install-Package FarNet.Redis -Version 0.7.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="FarNet.Redis" Version="0.7.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add FarNet.Redis --version 0.7.1
#r "nuget: FarNet.Redis, 0.7.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install FarNet.Redis as a Cake Addin
#addin nuget:?package=FarNet.Redis&version=0.7.1

// Install FarNet.Redis as a Cake Tool
#tool nuget:?package=FarNet.Redis&version=0.7.1

FarNet.Redis

StackExchange.Redis PowerShell module and FarNet library

The module provides PowerShell friendly wrappers for basic Redis types and operations. For not yet implemented or advanced operations (like getting byte[] data) use SERedis API methods directly, see examples in tests.

Redis keys, output simple values and complex type items are strings.
Input values may be anything supported by SERedis, including byte[].

Packages:

PowerShell module

You may install the PowerShell module by this command:

Install-Module -Name FarNet.Redis

Explore, see also about_FarNet.Redis.help.txt:

# import and get module commands
Import-Module -Name FarNet.Redis
Get-Command -Module FarNet.Redis

# get module and commands help
help about_FarNet.Redis
help Open-Redis
help Set-RedisString
help Get-RedisString
...

FarNet library

To install as the FarNet library FarNet.Redis, follow these steps.
The NuGet package is installed to %FARHOME%\FarNet\Lib\FarNet.Redis.

Included assets:

  • StackExchange.Redis.dll, FarNet.Redis.dll

    General purpose Redis client and helper assemblies.
    They are designed for using in C#, F#, PowerShell.

  • FarNet.Redis.psd1, PS.FarNet.Redis.dll

    PowerShell module files.

  • FarNet.Redis.ini

    F# scripts configuration, FarNet.FSharpFar.

The PowerShell module may be imported as:

Import-Module $env:FARHOME\FarNet\Lib\FarNet.Redis

Expose the module as a symbolic link or junction

Consider exposing this module, so that you can:

Import-Module FarNet.Redis

(1) Choose one of the module directories, see $env:PSModulePath.

(2) Change to the selected directory and create the symbolic link

New-Item FarNet.Redis -ItemType SymbolicLink -Value $env:FARHOME\FarNet\Lib\FarNet.Redis

(3) Alternatively, you may create the similar folder junction point in Far Manager using AltF6.

Then you may update the FarNet package with new versions. The symbolic link or junction do not have to be updated, they point to the same location.

Examples

See tests for all examples.

PowerShell

Import-Module FarNet.Redis
$db = Open-Redis 127.0.0.1:3278
Set-RedisString test:key1 Hello
Get-RedisString test:key1

F#

open StackExchange.Redis
let db = DB.Open("127.0.0.1:3278")
db.StringSet("test:key1", "Hello")
db.StringGet("test:key1")

Garnet server

Microsoft.Garnet is the Redis like server, especially useful on Windows.

Use a simple console project like GarnetServer to run your own server.

Notes

Open-Redis 127.0.0.1:3278 seems to work faster than using localhost.

See also

There are no supported framework assets in this package.

Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
0.7.1 35 4/28/2024
0.7.0 38 4/26/2024
0.6.1 53 4/24/2024
0.6.0 71 4/23/2024
0.5.3 74 4/21/2024
0.5.2 75 4/20/2024
0.5.1 112 4/16/2024
0.5.0 138 4/15/2024
0.4.0 147 4/14/2024
0.3.0 127 4/13/2024
0.2.0 136 4/8/2024
0.1.0 129 4/7/2024
0.0.3 119 4/6/2024
0.0.2 146 4/6/2024
0.0.1 150 4/6/2024