summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Hemminger <stephen.hemminger@vyatta.com>2009-06-01 11:17:04 -0700
committerStephen Hemminger <stephen.hemminger@vyatta.com>2009-06-01 11:17:04 -0700
commitaad699c42fd14ffde27bd3e44757dd049708e24c (patch)
tree387721ed8480d63cfcbfb467e4bc2475d07b0473
parent166cbc862b9a6dfd4a9e950effff39b03f0a4abd (diff)
downloadvyatta-op-aad699c42fd14ffde27bd3e44757dd049708e24c.tar.gz
vyatta-op-aad699c42fd14ffde27bd3e44757dd049708e24c.zip
Fix completion for VIF
Use COMP_WORDS to find real device name
-rw-r--r--templates/show/interfaces/bonding/node.tag/vif/node.tag/node.def2
-rw-r--r--templates/show/interfaces/ethernet/node.tag/vif/node.tag/node.def2
-rw-r--r--templates/show/interfaces/pseudo-ethernet/node.tag/vif/node.tag/node.def2
3 files changed, 3 insertions, 3 deletions
diff --git a/templates/show/interfaces/bonding/node.tag/vif/node.tag/node.def b/templates/show/interfaces/bonding/node.tag/vif/node.tag/node.def
index a7fe9ac..bcb688c 100644
--- a/templates/show/interfaces/bonding/node.tag/vif/node.tag/node.def
+++ b/templates/show/interfaces/bonding/node.tag/vif/node.tag/node.def
@@ -1,3 +1,3 @@
help: Show specified virtual network interface (vif) information
-allowed: ${vyatta_sbindir}/vyatta-interfaces.pl --show bonding --vif $4
+allowed: ${vyatta_sbindir}/vyatta-interfaces.pl --show bonding --vif ${COMP_WORDS[COMP_CWORD-2]}
run: ${vyatta_bindir}/vyatta-show-interfaces.pl --intf="$4.$6"
diff --git a/templates/show/interfaces/ethernet/node.tag/vif/node.tag/node.def b/templates/show/interfaces/ethernet/node.tag/vif/node.tag/node.def
index 88f6157..bc47fb6 100644
--- a/templates/show/interfaces/ethernet/node.tag/vif/node.tag/node.def
+++ b/templates/show/interfaces/ethernet/node.tag/vif/node.tag/node.def
@@ -1,3 +1,3 @@
help: Show specified virtual network interface (vif) information
-allowed: ${vyatta_sbindir}/vyatta-interfaces.pl --show ethernet --vif $4
+allowed: ${vyatta_sbindir}/vyatta-interfaces.pl --show ethernet --vif ${COMP_WORDS[COMP_CWORD-2]}
run: ${vyatta_bindir}/vyatta-show-interfaces.pl --intf="$4.$6"
diff --git a/templates/show/interfaces/pseudo-ethernet/node.tag/vif/node.tag/node.def b/templates/show/interfaces/pseudo-ethernet/node.tag/vif/node.tag/node.def
index 0a50960..5e3aae7 100644
--- a/templates/show/interfaces/pseudo-ethernet/node.tag/vif/node.tag/node.def
+++ b/templates/show/interfaces/pseudo-ethernet/node.tag/vif/node.tag/node.def
@@ -1,3 +1,3 @@
help: Show specified virtual network interface (vif) information
-allowed: ${vyatta_sbindir}/vyatta-interfaces.pl --show pseudo-ethernet --vif $4
+allowed: ${vyatta_sbindir}/vyatta-interfaces.pl --show pseudo-ethernet --vif ${COMP_WORDS[COMP_CWORD-2]}
run: ${vyatta_bindir}/vyatta-show-interfaces.pl --intf="$4.$6"