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

[BUG] can not escape sharps in git config file

From
Jean-Noël Avila <avila.jn@gmail.com>
Date
May 24, 2016, 10:14 UTC
Message-ID
<57442992.6030306@gmail.com>
Hi everyone,
I stumbled on this:
config file:
[filter "kicad_sch"]
        clean = sed -E 's/#(PWR|FLG)[0-9]+/#\1?/'
        smudge = cat
Then in the shell:

± git add -u sed -E 's/: 1: sed -E 's/: Syntax error: Unterminated quoted string error: external filter sed -E 's/ failed 2 error: external filter sed -E 's/ failed

It seems that the # is used for end-of-line comments and can not be escaped, even in quotes or backslash.

JN
Next: Jean-Noël Avila
Message 1 of 4 in “[BUG] can not escape sharps in git config file”
  1. Jean-Noël AvilaMay 24, 2016
  2. Jean-Noël AvilaMay 24, 2016
  3. Jean-Noël AvilaMay 24, 2016
  4. Torsten BögershausenMay 25, 2016

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.