Package: redis-server
Version: 2:1.2.0-1
Severity: wishlist
Tags: +patch

*** Please type your report below this line ***

  It would be useful to add a simple bash completion script to this
 package to ease use - as the manpage doesn't list options.

  Sample script attached below which you're welcome to use if you
 don't have the time/patience to write a better one.


-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-trunk-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages redis-server depends on:
ii  adduser                       3.112      add and remove users and groups
ii  libc6                         2.10.2-5   Embedded GNU C Library: Shared lib

redis-server recommends no packages.

redis-server suggests no packages.

-- no debconf information


# /etc/bash_completion.d/redis-cli.steve  # -*- sh -*-
#
# Bash completion function for the 'redis-cli' command.
#
# Steve
# --
# http://www.steve.org.uk
#


_redis-cli()
{
    COMPREPLY=()
    cur=${COMP_WORDS[COMP_CWORD]}
    prev=${COMP_WORDS[COMP_CWORD-1]}

    #
    #  All known commands accepted.  Sorted.
    #
    opts='bgrewriteaof bgsave dbsize debug decr decrby del echo exists expire 
expireat flushall flushdb get getset incr incrby info keys lastsave lindex llen 
lpop lpush lrange lrem lset ltrim mget move mset msetnx ping randomkey rename 
renamenx rewriteaof rpop rpoplpush rpush sadd save scard sdiff sdiffstore 
select set setnx shutdown sinter sinterstore sismember slaveof smembers smove 
sort spop srandmember srem sunion sunionstore ttl type zadd zcard zincrby 
zrange zrangebyscore zrem zremrangebyscore zrevrange zscore'

    #
    #  Only copmlete on the first term.
    #
    if [ $COMP_CWORD -eq 1 ]; then
        COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
        return 0
    fi

}
complete -F _redis-cli redis-cli


--
Steve
--



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to