From: Charles Bailey Date: Sun, 19 Apr 2015 00:28:07 GMT Subject: Re: [PATCH v8 2/4] cat-file: teach cat-file a '--literally' option Message-ID: <20150419002807.GA11634@hashpling.org> In-Reply-To: <1429117174-4968-1-git-send-email-karthik.188@gmail.com> On Wed, Apr 15, 2015 at 10:29:34PM +0530, Karthik Nayak wrote: > Currently 'git cat-file' throws an error while trying to > print the type or size of a broken/corrupt object. This is > because these objects are usually of unknown types. > > Teach git cat-file a '--literally' option where it prints > the type or size of a broken/corrupt object without throwing > an error. I'm sorry to come in with such a fundamental question at such a late revision of this patch series, but am I the only person to wonder about the choice of option name? To me, cat-file already output objects "literally" (without -p) as opposed to show. From the description, it feels more like it should be "--unchecked" or perhaps something better that I haven't thought of? The option isn't a true opposite of hash-object's --literally because that also allows the creation of known types with invalid contents (e.g. corrupt trees) whereas cat-file is quite happy to show the _contents_ of such corrupt objects even without --literally. Charles.