cat-file: split batch_one_object into two stages
commit44b877e9bc944258db096a0ec57151be7c8cbf66
authorJeff King <peff@peff.net>
Mon, 22 Jun 2015 10:45:41 +0000 (22 06:45 -0400)
committerJunio C Hamano <gitster@pobox.com>
Mon, 22 Jun 2015 21:55:52 +0000 (22 14:55 -0700)
treea0dfb70a1c31622cdd2ee1f3fde9f80d9945bc67
parent82330950d96a2c2b971ec5b29f59625bcfb62d47
cat-file: split batch_one_object into two stages

There are really two things going on in this function:

  1. We convert the name we got on stdin to a sha1.

  2. We look up and print information on the sha1.

Let's split out the second half so that we can call it
separately.

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