From 1a4ff3158b1034b51d102e7253115d514325c430 Mon Sep 17 00:00:00 2001
From: Daniel Shahaf <d.s@daniel.shahaf.name>
Date: Sun, 16 Jul 2017 18:25:25 +0000
Subject: [PATCH] completion: Set the context correctly in 'foreach'.

---
 _vcsh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/_vcsh b/_vcsh
index 3022c61..96ae612 100644
--- a/_vcsh
+++ b/_vcsh
@@ -24,7 +24,7 @@ function _vcsh-enter () {
 }
 
 function _vcsh-foreach () {
-	_dispatch git git
+	_dispatch vcsh-foreach git
 }
 
 function _vcsh-help () {
@@ -135,6 +135,7 @@ function _vcsh () {
 			if ! (( ${+functions[_vcsh-$vcshcommand]} )); then
 				# There is no handler function, so this is probably the name
 				# of a repository. Act accordingly.
+				# FIXME: this may want to use '_dispatch vcsh git'
 				_dispatch git git
 			else
 				curcontext="${curcontext%:*:*}:vcsh-${vcshcommand}:"
-- 
GitLab