redis command line interface like redis-cli support ssl and cluster mode
dependence: python3.6+, redis, prompt_toolkit
pip install redis
pip install prompt_toolkit==1.0.15
| struct SEQ_VAL { | |
| size_t start = 0, count = 0, mode = 0; | |
| }; | |
| int cg_compress(const unsigned char *src, size_t len, unsigned char *dest, unsigned char bgColor) { | |
| SEQ_VAL seq1, seq2; | |
| size_t dest_pos = 0; | |
| for (size_t i = 0; i < len; ++i) { | |
| switch (seq1.mode) { | |
| case MODE_NONE: |
| package com.example.demo; | |
| import com.google.gson.*; | |
| import com.google.gson.stream.JsonReader; | |
| import com.google.gson.stream.JsonWriter; | |
| import org.junit.jupiter.api.Test; | |
| import org.springframework.boot.test.context.SpringBootTest; | |
| import java.io.IOException; | |
| import java.util.ArrayList; |
| function hasProp(instance, prop) { | |
| let $options = instance.$options || {} | |
| let propsData = $options.propsData || {} | |
| return prop in propsData | |
| } | |
| function fx(self, binding, preCheck, action) { | |
| return function(...e) { | |
| let data = preCheck.call(this, ...e) | |
| if (!data) return |
| using System; | |
| using System.IO; | |
| using System.IO.Compression; | |
| using System.Linq; | |
| using System.Text.Json; | |
| using System.Text.Json.Serialization; | |
| using System.Text.RegularExpressions; | |
| using System.Threading; | |
| using System.Threading.Tasks; | |
| using StackExchange.Redis; |
| //Debug("Repl", "cancel") | |
| //field := reflect.ValueOf(*repl.promptInstance).Field(0) | |
| //WriteLn(field, field.Type(), field.Kind(), field.IsValid(), field.CanAddr(), field.CanInterface(), field.CanSet()) | |
| //pointer := reflect.ValueOf(field).Field(1).Pointer() | |
| ////WriteLn(*(*prompt.ConsoleParser)(unsafe.Pointer(pointer[0]))) | |
| //p := (*unsafe.Pointer)(unsafe.Pointer(pointer)) | |
| //WriteLn(p, *p) | |
| //parser := (*prompt.ConsoleParser)(unsafe.Pointer(p)) | |
| //WriteLn(parser) | |
| ////WriteLn(field.Addr()) |
| public class RequireIfAttribute : ValidationAttribute | |
| { | |
| public RequireIfMode Mode { get; } | |
| public Type TargetType { get; } | |
| public string Target { get; } | |
| public bool TargetEmptyAsExists { get; set; } |
| git svn propget svn:mergeinfo | % {[System.Text.Encoding]::UTF8.GetString([System.Text.Encoding]::Default.GetBytes($_))} |
| using System; | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using Microsoft.Xna.Framework; | |
| using Microsoft.Xna.Framework.Graphics; | |
| using SharpFont; | |
| namespace MonoFont | |
| { |
| #!/usr/local/bin/node | |
| let { execSync } = require('child_process') | |
| let args = process.argv.slice(2) | |
| let host = '' | |
| let port = '' | |
| let format = 'split' | |
| for (let i = 0; i < args.length; i++) { |