Hi Ville,
I fixed as you suggested and pulled a request to Github:
https://github.com/scop/bash-completion/pull/13
Very appriciated if you can review and give comments.
Thank you very much.
Best regards,
Liuhua
On Mon, Mar 07, 2016 at 04:10:57PM +0200, Ville Skyttä wrote:
> On Mon, Mar 7, 2016
On Mon, Mar 07, 2016 at 04:10:57PM +0200, Ville Skyttä wrote:
> On Mon, Mar 7, 2016 at 11:56 AM, Liuhua Wang wrote:
> > Liuhua Wang (3):
> > lvm: fix all commands that should get all PVs
> > lvm: pvcreate should be able to use all block devcices
> > lvm: disable silent temporarily to avoid n
On Mon, Mar 7, 2016 at 11:56 AM, Liuhua Wang wrote:
> Liuhua Wang (3):
> lvm: fix all commands that should get all PVs
> lvm: pvcreate should be able to use all block devcices
> lvm: disable silent temporarily to avoid no output
Looks like these changes no longer apply to the current master
Add _lvm_filedir() to use _filedir except set $cur to /dev
when $cur is empty.
Signed-off-by: Liuhua Wang
Reviewed-by: Lidong Zhong
---
completions/lvm | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/completions/lvm b/completions/lvm
index 1535c5c..e213967 100644
---
Liuhua Wang (3):
lvm: fix all commands that should get all PVs
lvm: pvcreate should be able to use all block devcices
lvm: disable silent temporarily to avoid no output
completions/lvm | 54 +++---
1 file changed, 47 insertions(+), 7 deletions
bash-completion will not work when /etc/lvm/lvm.conf silent is 1
because there is no output for vg/lv/pvscan.
So we check the value of silent option. If it is 1 then temporarily
set silent 0 and recover back to 1 after the command executed.
Signed-off-by: Liuhua Wang
Reviewed-by: Lidong Zhong
-
_lvm_physicalvolumes() only gets PVs that belong to a VG. In some
cases like pvremove we can use all PVs including those not included
in any VGs.
So we add a new function _lvm_physicalvolumes_all() to get all PVs,
and fix all the commands that need to use _lvm_physicalvolumes_all()
instead of _lvm