qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [GIT PULL for qemu-pseries] pseries: Update SLOF firmware image


From: Eric Blake
Subject: Re: [GIT PULL for qemu-pseries] pseries: Update SLOF firmware image
Date: Tue, 22 Oct 2019 20:07:51 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.1

On 10/22/19 7:04 PM, Alexey Kardashevskiy wrote:

Looking at commit 8e59d05f71ae which update the SLOF submodule,
in your future updates can you include the git shortlog in the
commit description?


I guess I can do that.

Is there an easy way to combine

git -C roms/SLOF shortlog qemu-slof-20190911..qemu-slof-20191022
git commit
?


git -C roms/SLOF shortlog qemu-slof-20190911..qemu-slof-20191022 \
  | git commit -F -


You can get something similar with less typing as:

git sumodule summary | git commit -F -


After
export MYDIFF=$(git -C roms/SLOF shortlog 
qemu-slof-20190911..qemu-slof-20191022)
$MYDIFF looses formatting (drops \r) so it is no good for a commit log.

Potentially insufficient quoting there.

POSIX says that:

export foo=$(printf 'a  b')

can result in either of the following scenarios:

both 'foo' and 'b' are exported, foo with the value 'a', b with its existing value (if any, otherwise empty); bash uses this behavior [in POSIX terms, bash treats arguments after 'export' in an assignment context]

just 'foo' is exported, with value 'a  b'; dash uses this behavior

If you want to guarantee the latter (that is, that the shell does not split on whitespace or perform globbing), you have to either split it into two commands (so that your unquoted use of $() is guaranteed to occur in assignment context, without worrying whether 'export' introduces those contexts):

export foo
foo=$(...)

or use quoting:

export foo="$(...)"

--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3226
Virtualization:  qemu.org | libvirt.org




reply via email to

[Prev in Thread] Current Thread [Next in Thread]