git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [COGITO PATCH] Fix cg-log and cg-status for non-GNU sed/sort

From
Petr Baudis <pasky@ucw.cz>
Date
May 29, 2005, 23:16 UTC
Message-ID
<20050529231652.GX1036@pasky.ji.cz>
In-Reply-To
<20050529230011.30885.qmail@web41201.mail.yahoo.com>

Dear diary, on Mon, May 30, 2005 at 01:00:10AM CEST, I got a letter where Mark Allen <mrallen1@yahoo.com> told me that...

> Here're a couple of pretty simple patches against cg-log and cg-status (two cogito
> commands I use a lot) for the non-GNU (or at least older, forked GNU) tools on Darwin.
Show 6 quoted lines
> @@ -148,10 +148,10 @@
>                                 fi
> 
>                                 date=(${rest#*> })
> -                               pdate="$(showdate $date)"
> +                               pdate="$(date -u -r $date)"

Hmm, coudlnt' showdate be fixed instead then? And $date is not a file so -r $date makes no sense to me - what am I missing?

Show 5 quoted lines
>                                 if [ "$pdate" ]; then
> -                                       echo -n $color$key $rest | sed "s/>.*/> $pdate/"
> -                                       echo $coldefault
> +                                       echo -n $color$key $rest | sed "s/>.*/> $pdate/"
> +                                       echo -n $coldefault
I'm lost on this one too. Why do you introduce the -n?
Show 15 quoted lines
>                                 else
>                                         echo $color$key $rest $coldefault
>                                 fi
> @@ -168,11 +168,8 @@
>                                 if [ -n "$list_files" ]; then
>                                         list_commit_files "$tree1" "$tree2"
>                                 fi
> -                               echo; sed -re '
> -                                       / *Signed-off-by:.*/Is//'$colsignoff'&'$coldefault'/
> -                                       / *Acked-by:.*/Is//'$colsignoff'&'$coldefault'/
> -                                       s/./    &/
> -                               '
> +                               echo; sed -e "/ *Signed-off-by:.*/s/ *Signed-off-by:.*/$colsignoff&$coldefault/" -e"/
> +*Acked-by:.*/s/ *Acked-by:.*/$colsignoff&$coldefault/" -e "s/./    &/"
> +

Is it necessary to take away the newlines? What is the real problem, actually? Just the I flag?

Could you please sign the patch off, and send it as text/plain or inline the message body?

Thanks,
-- 
				Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
C++: an octopus made by nailing extra legs onto a dog. -- Steve Taylor
Previous: Mark AllenNext: Mark Allen
Message 2 of 6 in “Fix cg-log and cg-status for non-GNU sed/sort”
  1. Fix cg-log and cg-status for non-GNU sed/sortMark Allen, May 29, 2005
  2. Petr BaudisMay 29, 2005
  3. Mark AllenMay 29, 2005
  4. Petr BaudisMay 29, 2005
  5. Alecs KingMay 30, 2005
  6. Mark AllenMay 31, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.