public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: "Boyd Stephen Smith Jr." <bss03@volumehost•net>
To: git@vger•kernel.org
Cc: Simon 'corecode' Schubert <corecode@fs•ei.tum.de>
Subject: Re: [PATCH] Allow passing of --directory to git-am.
Date: Thu, 4 Dec 2008 12:28:58 -0600	[thread overview]
Message-ID: <200812041228.58885.bss03@volumehost.net> (raw)
In-Reply-To: <49380D84.5050403@fs.ei.tum.de>

[-- Attachment #1: Type: text/plain, Size: 830 bytes --]

On Thursday 04 December 2008, Simon 'corecode' Schubert 
<corecode@fs•ei.tum.de> wrote about '[PATCH] Allow passing of --directory 
to git-am.':
>-	--whitespace)
>-		git_apply_opt="$git_apply_opt $1=$2"; shift ;;
>+	--whitespace|--directory)
>+		quot=$(echo "$2" | sed -e "s/'/\\'/g")
>+		git_apply_opt="$git_apply_opt $1='$quot'"; shift ;;

Test:
bss@monster:~$ echo "don't" | sed -e "s/'/\\'/g"
don't
bss@monster:~$

I'm thinking your sed line doesn't do what you think it does.  You probably 
want something like:
bss@monster:~$ echo "don't" | sed -e "s/'/'\\\\''/g"
don'\''t
-- 
Boyd Stephen Smith Jr.                     ,= ,-_-. =. 
bss03@volumehost•net                      ((_/)o o(\_))
ICQ: 514984 YM/AIM: DaTwinkDaddy           `-'(. .)`-' 
http://iguanasuicide.org/                      \_/     

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

  reply	other threads:[~2008-12-04 18:30 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-04 17:04 [PATCH] Allow passing of --directory to git-am Simon 'corecode' Schubert
2008-12-04 18:28 ` Boyd Stephen Smith Jr. [this message]
  -- strict thread matches above, loose matches on Subject: below --
2008-12-04 18:48 Simon 'corecode' Schubert
2008-12-04 18:51 ` Jeff King
2008-12-04 19:27 ` Junio C Hamano
2008-12-04 22:26   ` Simon 'corecode' Schubert
2008-12-04 22:33     ` Junio C Hamano
2008-12-04 23:14       ` Junio C Hamano
2008-12-04 23:41       ` Simon 'corecode' Schubert
2008-12-05  0:11         ` Junio C Hamano
2008-12-05  0:16           ` Simon 'corecode' Schubert
2008-12-04 19:35 ` Jakub Narebski
2008-12-04 22:25   ` Simon 'corecode' Schubert
2008-12-04 22:46     ` Jakub Narebski

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=200812041228.58885.bss03@volumehost.net \
    --to=bss03@volumehost$(echo .)net \
    --cc=corecode@fs$(echo .)ei.tum.de \
    --cc=git@vger$(echo .)kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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