Skip to content

Instantly share code, notes, and snippets.

@itamarhaber
Created May 23, 2014 15:41
Show Gist options
  • Save itamarhaber/365c8c61fc9bfb3f6824 to your computer and use it in GitHub Desktop.
Save itamarhaber/365c8c61fc9bfb3f6824 to your computer and use it in GitHub Desktop.
Redis suffix index function in Lua. Call with key name of the search terms set and argument to index
redis.call("zadd", KEYS[1], 1, ARGV[1]:reverse())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment