rev-parse: use skip_prefix when parsing options
commitef87cc79dff1fa0d16ad4d67646afeba9ce11a6c
authorJeff King <peff@peff.net>
Wed, 15 Mar 2017 20:05:36 +0000 (15 16:05 -0400)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 Mar 2017 21:00:28 +0000 (15 14:00 -0700)
treefe96309569d22a594af9dcdc898adbdf70c69e7c
parente7e07d5a4fcc2a203d9873968ad3e6bd4d7419d7
rev-parse: use skip_prefix when parsing options

Using skip_prefix lets us avoid manually-counted offsets
into the argument string. This patch converts the simple and
obvious cases.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/rev-parse.c