git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dave Bradley <dbradley2@bell.net>
To: <kusmabite@gmail.com>, "Jonathan Nieder" <jrnieder@gmail.com>
Cc: "GIT Mailing-list" <git@vger.kernel.org>,
	"msysGit" <msysgit@googlegroups.com>
Subject: Re: [msysGit] Re: #178 parsing of pretty=format:"%an %ad" causes fatal: bad revision '%ad'
Date: Sun, 4 May 2014 06:14:13 -0400	[thread overview]
Message-ID: <BLU0-SMTP387BC836A8719897DD84B79F4D0@phx.gbl> (raw)
In-Reply-To: <CABPQNSYTWYwSgd=sa0QGmaFDuzprLzLNYmQEx-6MrZ_HEZimww@mail.gmail.com>

Hi,

Interesting discussion. However, the example below of three-spaces between 
"%an"  and "%ad" in the example below resulted in the
formatting of the output with the three spaces,  but no dq's.

> Original #178 content
>G:\ws_test_env\GIT_TESTBED_TMP\fest-swing-1.x>git log --all 
>"--pretty=format:"%an"    "%ad"" -- pom.xml
>xxxx xxxx    Mon Nov 23 03:09:17 2009 +0000
>xxxx xxxx    Mon Nov 23 02:42:24 2009 +0000

This added to my confusion as by right dq within dq should be formatted. 
(Yea right, these days its needs to be escaped. But haven't tried that.)

In summary so far, it would appear that the --pretty......... needs to be 
contained in double-quotes as a whole. This was the solution I applied to my 
problem.

In the discussions I've seen more information requested as to the arguments 
provided to the execution class. I solved this issue as I made it work by 
experiment. I format the argument as a whole and don't have the space. IE. 
"pretty=format:"name:%an%nauthor:%ad%n"".


Regards

-----Original Message----- 
From: Erik Faye-Lund
Sent: Friday, May 02, 2014 2:23 PM
To: Jonathan Nieder
Cc: Dave Bradley ; GIT Mailing-list ; msysGit
Subject: Re: [msysGit] Re: #178 parsing of pretty=format:"%an %ad" causes 
fatal: bad revision '%ad'

On Fri, May 2, 2014 at 7:23 PM, Jonathan Nieder <jrnieder@gmail.com> wrote:
> (resending with the correct address for the Git for Windows developers.
> Sorry for the noise.)
> Hi Dave,
>
> Dave Bradley wrote:
>
>> G:\ws_test_env\GIT_TESTBED_TMP\fest-swing-1.x>git 
>> log --all --pretty=format:"%an %ad" -- pom.xml
>> xxxx xxxx Mon Nov 23 03:09:17 2009 +0000
>> xxxx xxxx Mon Nov 23 02:42:24 2009 +0000
>>
>> G:\ws_test_env\GIT_TESTBED_TMP\fest-swing-1.x>git log --all 
>> "--pretty=format:"%an %ad"" -- pom.xml
>> fatal: bad revision '%ad'
>
> On Linux, this example gets passed to git as six arguments:
>
>         log
>         --all
>         --pretty=format:%an
>         %ad
>         --
>         pom.xml
>

As does it on Windows. 

  reply	other threads:[~2014-05-04 10:19 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-02 11:50 #178 parsing of pretty=format:"%an %ad" causes fatal: bad revision '%ad' Dave Bradley
2014-05-02 12:12 ` Erik Faye-Lund
2014-05-02 17:18   ` Junio C Hamano
2014-05-02 17:22 ` Jonathan Nieder
2014-05-02 17:23 ` Jonathan Nieder
2014-05-02 18:23   ` Erik Faye-Lund
2014-05-04 10:14     ` Dave Bradley [this message]
2014-05-05 23:02       ` [msysGit] " Junio C Hamano

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

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

  git send-email \
    --in-reply-to=BLU0-SMTP387BC836A8719897DD84B79F4D0@phx.gbl \
    --to=dbradley2@bell.net \
    --cc=git@vger.kernel.org \
    --cc=jrnieder@gmail.com \
    --cc=kusmabite@gmail.com \
    --cc=msysgit@googlegroups.com \
    /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.
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 NNTP newsgroup(s).