git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Stefan Beller <sbeller@google.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Jeff King <peff@peff.net>,
	Johannes Schindelin <johannes.schindelin@gmx.de>,
	Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>,
	Faheem Mitha <faheem@faheem.info>,
	"git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: [PUB]corrupt repos does not return error with `git fsck`
Date: Wed, 20 May 2015 14:13:19 -0700	[thread overview]
Message-ID: <CAGZ79kab8a9H2SFaqi2PFLxhqH86wD35STPo0Jw7CyFe7e9tig@mail.gmail.com> (raw)
In-Reply-To: <xmqq4mn7m00c.fsf@gitster.dls.corp.google.com>

On Wed, May 20, 2015 at 2:06 PM, Junio C Hamano <gitster@pobox.com> wrote:
> Stefan Beller <sbeller@google.com> writes:
>
>> On Wed, May 20, 2015 at 1:39 PM, Junio C Hamano <gitster@pobox.com> wrote:
>>>
>>> So...
>>
>> maybe we need a command:
>>
>> Given this SHA1, tell me anything you know about it,
>> Is it a {blob,tree,commit,tag}?
>> Is it referenced from anywhere else in this repository and if so, which type?
>> And if it is not referenced, nor an object, tell me so explicitely.
>
> Let me add another to that list ;-)
>
>   I have this prefix; please enumerate all known objects that share it.
>
> I do not know the value of the first two in your list.  If it is a
> known object, then you throw it at "git show", "git cat-file -t" and
> dig from there.  If it is not known, there is nothing more to do.

Right, I just tried to think of all the questions which are relevant to answer
in such a case, so probably this can be outside of

>
> I do not know if "need" is the right word, but I hope that you
> realize the last two among the four you listed need the equivalent
> of "git fsck".  It is an expensive operation.

Yes, I do realize that. The way I interpreted Faheems original message was:

    git fsck tells me everything is alright, but I don't trust fsck.
So now I want
    to find a way to ask Git about everything it knows about this
$SHA1 and print
    it for me so I can manually look at each entry and verify by hand.

So that's why I included the parts easily done with cat-file and show.

  reply	other threads:[~2015-05-20 21:13 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-20 16:17 corrupt repos does not return error with `git fsck` Faheem Mitha
2015-05-20 17:19 ` [PUB]corrupt " Matthieu Moy
2015-05-20 17:40   ` Johannes Schindelin
2015-05-20 18:02     ` Stefan Beller
2015-05-20 18:19       ` John Keeping
2015-05-20 18:22       ` Jeff King
2015-05-20 18:31         ` Jeff King
2015-05-20 20:39           ` Junio C Hamano
2015-05-20 20:57             ` Stefan Beller
2015-05-20 21:06               ` Junio C Hamano
2015-05-20 21:13                 ` Stefan Beller [this message]
2015-05-20 21:55             ` Jeff King
2015-05-20 20:16         ` Junio C Hamano
2015-05-20 18:24       ` Faheem Mitha
2015-05-20 18:54         ` Stefan Beller
2015-05-20 19:13           ` Faheem Mitha
2015-05-20 21:03       ` Matthieu Moy
2015-05-20 17:58   ` Faheem Mitha
2015-05-21  8:09     ` Matthieu Moy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAGZ79kab8a9H2SFaqi2PFLxhqH86wD35STPo0Jw7CyFe7e9tig@mail.gmail.com \
    --to=sbeller@google.com \
    --cc=Matthieu.Moy@grenoble-inp.fr \
    --cc=faheem@faheem.info \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=johannes.schindelin@gmx.de \
    --cc=peff@peff.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).