Re: [PATCH] Add list-all-objects command
- From
Jeff King <peff@peff.net>
- Date
- Jun 22, 2015, 08:38 UTC
- Message-ID
- <20150622083822.GB12259@peff.net>
- In-Reply-To
- <1434914431-7745-2-git-send-email-charles@hashpling.org>
On Sun, Jun 21, 2015 at 08:20:31PM +0100, Charles Bailey wrote:
Show 7 quoted lines
> +OPTIONS > +------- > + > +-v:: > +--verbose:: > + Output in the followin format instead of just printing object ids: > + <sha1> SP <type> SP <size>
s/followin/&g/
Show 13 quoted lines
> +int cmd_list_all_objects(int argc, const char **argv, const char *prefix)
> +{
> + struct packed_git *p;
> +
> + argc = parse_options(argc, argv, prefix, builtin_filter_objects_options,
> + NULL, 0);
> +
> + for_each_loose_object(check_loose_object, NULL, 0);
> +
> + prepare_packed_git();
> + for (p = packed_git; p; p = p->next) {
> + open_pack_index(p);
> + }Yikes. The fact that you need to do this means that for_each_packed_object is buggy, IMHO. I'll send a patch.
-Peff