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

Re: [PATCH 4/4] contrib/subtree: Replace invisible carriage return with a visible \r

From
Paul Campbell <pcampbell@kemitix.net>
Date
Mar 13, 2013, 22:36 UTC
Message-ID
<CALeLG_kSye2xRoUJ8ytjx-bsj6oSG_brPbj-X3yfXuLA-KEppA@mail.gmail.com>
In-Reply-To
<1363213963-4065-5-git-send-email-pcampbell@kemitix.net>
On Wed, Mar 13, 2013 at 10:32 PM, Paul Campbell <pcampbell@kemitix.net> wrote:
Show 14 quoted lines
> From: Matt Hoffman <matt.hoffman@quantumretail.com>
>
> The ctrl-M (^M) character used for the carriage return (CR) is not visible
> in all (most) text editors and is often silently converted to a new
> line (NL) or CR/NL combo.
>
> 'say' is a wrapper for echo with accepts the option -e to interperet
> escaped characters. \r becomes a CR, yet is not munged by text
> editors.
>
> Signed-off-by: Paul Campbell <pcampbell@kemitix.net>
>
> Conflicts:
>         git-subtree.sh
Oops. Meant to replace this Conflict line.
Show 21 quoted lines
> ---
>  contrib/subtree/git-subtree.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/contrib/subtree/git-subtree.sh b/contrib/subtree/git-subtree.sh
> index 2d9b071..5314bd0 100755
> --- a/contrib/subtree/git-subtree.sh
> +++ b/contrib/subtree/git-subtree.sh
> @@ -595,7 +595,7 @@ cmd_split()
>         eval "$grl" |
>         while read rev parents; do
>                 revcount=$(($revcount + 1))
> -               say -n "$revcount/$revmax ($createcount)
> "
> +               say -ne "$revcount/$revmax ($createcount)\r"
>                 debug "Processing commit: $rev"
>                 exists=$(cache_get $rev)
>                 if [ -n "$exists" ]; then
> --
> 1.8.2
>
-- 
Paul [W] Campbell
Previous: Paul CampbellNext: Paul Campbell
Message 6 of 10 in “contrib/subtree: general updates”
  1. 0/4 contrib/subtree: general updatesPaul Campbell, Mar 13, 2013
  2. 1/4 contrib/subtree: Teach push to abort if split failsPaul Campbell, Mar 13, 2013
  3. 2/4 contrib/subtree: Teach push to use --force optionPaul Campbell, Mar 13, 2013
  4. 3/4 contrib/subtree: Fix typo (s/incldued/included/)Paul Campbell, Mar 13, 2013
  5. 4/4 contrib/subtree: Replace invisible carriage return with a visible \rPaul Campbell, Mar 13, 2013
  6. Paul CampbellMar 13, 2013
  7. contrib/subtree: Replace invisible carriage return with a visible \rPaul Campbell, Mar 13, 2013
  8. Miles BaderMar 14, 2013
  9. Junio C HamanoMar 14, 2013
  10. Paul CampbellMar 24, 2013

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.