From: Matthieu Moy <Matthieu.Moy@grenoble-inp.fr>
To: Yauheni Zablotski <e.zablotski@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: bug "$message" literal in commit message
Date: Wed, 03 Jun 2015 20:19:13 +0200 [thread overview]
Message-ID: <vpqiob47izi.fsf@anie.imag.fr> (raw)
In-Reply-To: <CAF-5DQ+WGhHq0OZZh+90iuD1qrffcYyuprzW9m7XC6NGXPZzSQ@mail.gmail.com> (Yauheni Zablotski's message of "Wed, 3 Jun 2015 18:51:10 +0200")
Yauheni Zablotski <e.zablotski@gmail.com> writes:
> Hello,
>
> I think I found a bug(or strange behavior) in the git.
> If commit message contains literal "$message" than that literal
> disappears from commit message.
>
> For example:
> -------------
> user@comp ~/cc $ git commit -am "1$message1"
Not a Git issue, but a user-error that Git cannot recover.
Your shell is doing the variable expansion before calling git, and
$message1 is considered as a shell variable here. Git does not know that
you used $message1.
Solution:
git commit -am '1$message1'
or
git commit -am "1\$message1"
--
Matthieu Moy
http://www-verimag.imag.fr/~moy/
prev parent reply other threads:[~2015-06-03 18:19 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-03 16:51 bug "$message" literal in commit message Yauheni Zablotski
2015-06-03 18:16 ` Junio C Hamano
2015-06-03 18:19 ` Matthieu Moy [this message]
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=vpqiob47izi.fsf@anie.imag.fr \
--to=matthieu.moy@grenoble-inp.fr \
--cc=e.zablotski@gmail.com \
--cc=git@vger.kernel.org \
/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