]> git.proxmox.com Git - ceph.git/blame - ceph/src/bash_completion/rados
update sources to ceph Nautilus 14.2.1
[ceph.git] / ceph / src / bash_completion / rados
CommitLineData
7c673cae
FG
1#
2# Ceph - scalable distributed file system
3#
4# Copyright (C) 2011 Wido den Hollander <wido@widodh.nl>
5#
6# This is free software; you can redistribute it and/or
7# modify it under the terms of the GNU Lesser General Public
8# License version 2.1, as published by the Free Software
9# Foundation. See file COPYING.
10#
11
12_rados()
13{
14 local cur prev
15
16 COMPREPLY=()
17 cur="${COMP_WORDS[COMP_CWORD]}"
18 prev="${COMP_WORDS[COMP_CWORD-1]}"
19
20 if [[ ${cur} == -* ]] ; then
21 COMPREPLY=( $(compgen -W "-c --conf -m -d -f -p --pool -b --snap -i -o --create" -- ${cur}) )
22 return 0
23 fi
24
25 case "${prev}" in
26 --conf | -c | -o | -i)
27 COMPREPLY=( $(compgen -f ${cur}) )
28 return 0
29 ;;
30 -m)
31 COMPREPLY=( $(compgen -A hostname ${cur}) )
32 return 0
33 ;;
34 rados)
11fdf7f2 35 COMPREPLY=( $(compgen -W "lspools df ls chown get put create rm listxattr getxattr setxattr rmxattr stat stat2 mapext lssnap mksnap rmsnap rollback bench" -- ${cur}) )
7c673cae
FG
36 return 0
37 ;;
38 esac
39}
40complete -F _rados rados