summaryrefslogtreecommitdiffstats
path: root/iredis/data/commands/persist.md
diff options
context:
space:
mode:
Diffstat (limited to 'iredis/data/commands/persist.md')
-rw-r--r--iredis/data/commands/persist.md20
1 files changed, 20 insertions, 0 deletions
diff --git a/iredis/data/commands/persist.md b/iredis/data/commands/persist.md
new file mode 100644
index 0000000..4819230
--- /dev/null
+++ b/iredis/data/commands/persist.md
@@ -0,0 +1,20 @@
+Remove the existing timeout on `key`, turning the key from _volatile_ (a key
+with an expire set) to _persistent_ (a key that will never expire as no timeout
+is associated).
+
+@return
+
+@integer-reply, specifically:
+
+- `1` if the timeout was removed.
+- `0` if `key` does not exist or does not have an associated timeout.
+
+@examples
+
+```cli
+SET mykey "Hello"
+EXPIRE mykey 10
+TTL mykey
+PERSIST mykey
+TTL mykey
+```