From: Junio C Hamano Date: Mon, 31 Jul 2006 10:06:09 GMT Subject: Re: git-checkout doesn't understand -- separator Message-ID: <7vvepe6qcu.fsf@assigned-by-dhcp.cox.net> In-Reply-To: Jakub Narebski writes: > git-checkout doesn't understand '--' as a separator between (which > is optional, but you can always write HEAD), and ... > > 1144:jnareb@roke:~/git> git checkout HEAD^ -- gitweb/gitweb.cgi > git-checkout-index: -- is not in the cache > > Strange... Perhaps... diff --git a/git-checkout.sh b/git-checkout.sh index 5613bfc..580a9e8 100755 --- a/git-checkout.sh +++ b/git-checkout.sh @@ -67,6 +67,10 @@ while [ "$#" != "0" ]; do set x "$arg" "$@" shift fi + case "$1" in + --) + shift ;; + esac break ;; esac