From 4426adc860aae79e260f5fd14c871fa5a15f741e Mon Sep 17 00:00:00 2001 From: John Southworth Date: Tue, 28 Jun 2011 12:09:59 -0500 Subject: Don't guide disk-install files to /config as it doesn't exist. fix file detection for disk-install --- etc/bash_completion.d/vyatta-op | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/etc/bash_completion.d/vyatta-op b/etc/bash_completion.d/vyatta-op index 081e8a6..7226134 100644 --- a/etc/bash_completion.d/vyatta-op +++ b/etc/bash_completion.d/vyatta-op @@ -435,6 +435,8 @@ _vyatta_image_is_file() cur=${cur#$topdir/} if [[ $topdir == "running" ]]; then cur="/${cur}" + elif [[ $topdir == "disk-install" ]]; then + cur="/live/image/${cur}" else cur="/live/image/boot/${topdir}/live-rw/${cur}" fi @@ -472,7 +474,7 @@ _vyatta_image_path_complete() done reply+=( "running://config/" ) if [[ -d /live/image/opt/vyatta/etc/config || -d /live/image/config ]]; then - reply+=( "disk-install://config/" ) + reply+=( "disk-install://" ) fi else if ! [[ $cur =~ .*:\/\/ ]]; then @@ -497,7 +499,7 @@ _vyatta_image_path_complete() if [[ $isrunningimg == "running" ]];then reply[$i]="running://config/" elif [[ $isdiskinstall == "disk-install" ]]; then - reply[$i]="disk-install://config/" + reply[$i]="disk-install://" else reply[$i]=${file/#\/live\/image\/boot\//} if [[ -d /live/image/boot/${reply[$i]} ]]; then -- cgit v1.2.3