Skip to content

Commit 065bd98

Browse files
authored
Add CLI commands for Redis 7.0.0 (#80)
1 parent 3e04b15 commit 065bd98

File tree

1 file changed

+24
-8
lines changed

1 file changed

+24
-8
lines changed

src/redis-cli-panel/help/redis.ts

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -655,17 +655,17 @@ export const RedisHelp: { [key: string]: HelpCommand } = {
655655
url: 'https://redis.io/commands/exists',
656656
},
657657
EXPIRE: {
658-
syntax: 'EXPIRE key seconds',
658+
syntax: 'EXPIRE key seconds [NX|XX|GT|LT]',
659659
summary: "Set a key's time to live in seconds.",
660660
complexity: 'O(1)',
661-
since: '1.0.0',
661+
since: '1.0.0, >= 7.0: Added options: NX, XX, GT and LT.',
662662
url: 'https://redis.io/commands/expire',
663663
},
664664
EXPIREAT: {
665-
syntax: 'EXPIREAT key timestamp',
665+
syntax: 'EXPIREAT key timestamp [NX|XX|GT|LT]',
666666
summary: 'Set the expiration for a key as a UNIX timestamp.',
667667
complexity: 'O(1)',
668-
since: '1.2.0',
668+
since: '1.2.0, >= 7.0: Added options: NX, XX, GT and LT.',
669669
url: 'https://redis.io/commands/expireat',
670670
},
671671
FAILOVER: {
@@ -1226,17 +1226,17 @@ export const RedisHelp: { [key: string]: HelpCommand } = {
12261226
url: 'https://redis.io/commands/persist',
12271227
},
12281228
PEXPIRE: {
1229-
syntax: 'PEXPIRE key milliseconds',
1229+
syntax: 'PEXPIRE key milliseconds [NX|XX|GT|LT]',
12301230
summary: "Set a key's time to live in milliseconds.",
12311231
complexity: 'O(1)',
1232-
since: '2.6.0',
1232+
since: '2.6.0, >= 7.0: Added options: NX, XX, GT and LT.',
12331233
url: 'https://redis.io/commands/pexpire',
12341234
},
12351235
PEXPIREAT: {
1236-
syntax: 'PEXPIREAT key milliseconds-timestamp',
1236+
syntax: 'PEXPIREAT key milliseconds-timestamp [NX|XX|GT|LT]',
12371237
summary: 'Set the expiration for a key as a UNIX timestamp specified in milliseconds.',
12381238
complexity: 'O(1)',
1239-
since: '2.6.0',
1239+
since: '2.6.0, >= 7.0: Added options: NX, XX, GT and LT.',
12401240
url: 'https://redis.io/commands/pexpireat',
12411241
},
12421242
PFADD: {
@@ -1441,6 +1441,13 @@ export const RedisHelp: { [key: string]: HelpCommand } = {
14411441
since: '1.0.0',
14421442
url: 'https://redis.io/commands/scard',
14431443
},
1444+
SINTERCARD: {
1445+
syntax: 'SINTERCARD key [key ...]',
1446+
summary: 'Returns the cardinality of the set which would result from the intersection of all the given sets.',
1447+
complexity: 'O(N*M) worst case where N is the cardinality of the smallest set and M is the number of sets.',
1448+
since: '7.0.0',
1449+
url: 'https://redis.io/commands/sintercard',
1450+
},
14441451

14451452
/**
14461453
* Script
@@ -1784,6 +1791,15 @@ export const RedisHelp: { [key: string]: HelpCommand } = {
17841791
since: '1.2.0',
17851792
url: 'https://redis.io/commands/zcard',
17861793
},
1794+
ZINTERCARD: {
1795+
syntax: 'ZINTERCARD numkeys key [key ...]',
1796+
summary:
1797+
'This command is similar to ZINTER, but instead of returning the result set, it returns just the cardinality of the result.',
1798+
complexity:
1799+
'O(N*K) worst case with N being the smallest input sorted set, K being the number of input sorted sets.',
1800+
since: '7.0.0',
1801+
url: 'https://redis.io/commands/zintercard',
1802+
},
17871803
ZCOUNT: {
17881804
syntax: 'ZCOUNT key min max',
17891805
summary: 'Count the members in a sorted set with scores within the given values.',

0 commit comments

Comments
 (0)