mbox series

[00/10] Trivial fixes and clean ups

Message ID 20181004161852.11673-1-crosa@redhat.com (mailing list archive)
Headers show
Series Trivial fixes and clean ups | expand

Message

Cleber Rosa Oct. 4, 2018, 4:18 p.m. UTC
Just a collection of trivial fixes and clean ups that have been lying
around here for some time.

Cleber Rosa (10):
  qemu-img.c: comment typo fix
  tests/tcg/README: fix location for lm32 tests
  qemu-iotests: make 218 executable
  qemu-iotests: fix filename containing checks
  docs/devel/testing.rst: add missing newlines after code block
  thunk.c: clean up commented out definition
  scripts/decodetree.py: remove unused imports
  scripts/decodetree.py: fix reference to attributes
  scripts/qemu.py: use a more consistent docstring style
  scripts/qemu.py: remove trailing quotes on docstring

 docs/devel/testing.rst       |  2 ++
 dtc                          |  2 +-
 qemu-img.c                   |  2 +-
 scripts/decodetree.py        |  4 +--
 scripts/qemu.py              | 67 ++++++++++++++++++++++--------------
 tests/qemu-iotests/218       |  0
 tests/qemu-iotests/common.rc |  4 +--
 tests/tcg/README             |  2 +-
 thunk.c                      |  2 --
 9 files changed, 50 insertions(+), 35 deletions(-)
 mode change 100644 => 100755 tests/qemu-iotests/218

Comments

Eric Blake Oct. 4, 2018, 4:48 p.m. UTC | #1
On 10/4/18 11:18 AM, Cleber Rosa wrote:
> Commit 990dc39c made all tests executable at the time, but 218 came in
> later, and missing those permissions.
> 
> Signed-off-by: Cleber Rosa <crosa@redhat.com>
> ---
>   tests/qemu-iotests/218 | 0
>   1 file changed, 0 insertions(+), 0 deletions(-)
>   mode change 100644 => 100755 tests/qemu-iotests/218
> 
> diff --git a/tests/qemu-iotests/218 b/tests/qemu-iotests/218
> old mode 100644
> new mode 100755

Reviewed-by: Eric Blake <eblake@redhat.com>
Philippe Mathieu-Daudé Oct. 5, 2018, 1:36 p.m. UTC | #2
On 04/10/2018 18:18, Cleber Rosa wrote:
> Commit 990dc39c made all tests executable at the time, but 218 came in
> later, and missing those permissions.
> 
> Signed-off-by: Cleber Rosa <crosa@redhat.com>
> ---
>  tests/qemu-iotests/218 | 0
>  1 file changed, 0 insertions(+), 0 deletions(-)
>  mode change 100644 => 100755 tests/qemu-iotests/218
> 
> diff --git a/tests/qemu-iotests/218 b/tests/qemu-iotests/218
> old mode 100644
> new mode 100755

We could add a git pre-commit hook grep'ing for "^#!\
*(/usr/bin/env|/bin/(b?a)?sh)" in the 1st line and then checking the
file perms.
Cleber Rosa Oct. 5, 2018, 5:49 p.m. UTC | #3
On 10/5/18 9:36 AM, Philippe Mathieu-Daudé wrote:
> On 04/10/2018 18:18, Cleber Rosa wrote:
>> Commit 990dc39c made all tests executable at the time, but 218 came in
>> later, and missing those permissions.
>>
>> Signed-off-by: Cleber Rosa <crosa@redhat.com>
>> ---
>>  tests/qemu-iotests/218 | 0
>>  1 file changed, 0 insertions(+), 0 deletions(-)
>>  mode change 100644 => 100755 tests/qemu-iotests/218
>>
>> diff --git a/tests/qemu-iotests/218 b/tests/qemu-iotests/218
>> old mode 100644
>> new mode 100755
> 
> We could add a git pre-commit hook grep'ing for "^#!\
> *(/usr/bin/env|/bin/(b?a)?sh)" in the 1st line and then checking the
> file perms.
> 

Good idea.  Probably better to send that as a different patch, right?
Eric Blake Oct. 5, 2018, 6:02 p.m. UTC | #4
On 10/5/18 12:49 PM, Cleber Rosa wrote:

>>
>> We could add a git pre-commit hook grep'ing for "^#!\
>> *(/usr/bin/env|/bin/(b?a)?sh)" in the 1st line and then checking the
>> file perms.
>>
> 
> Good idea.  Probably better to send that as a different patch, right?

Yes, separate patch. For that matter, "^#!/" is probably a sufficient 
pattern to catch any file that intends to be run via an interpreter, and 
therefore wants to be executable, rather than limiting to just env and 
specific shells.
Eric Blake Oct. 5, 2018, 6:19 p.m. UTC | #5
On 10/5/18 1:02 PM, Eric Blake wrote:
> On 10/5/18 12:49 PM, Cleber Rosa wrote:
> 
>>>
>>> We could add a git pre-commit hook grep'ing for "^#!\
>>> *(/usr/bin/env|/bin/(b?a)?sh)" in the 1st line and then checking the
>>> file perms.
>>>
>>
>> Good idea.  Probably better to send that as a different patch, right?
> 
> Yes, separate patch. For that matter, "^#!/" is probably a sufficient 
> pattern to catch any file that intends to be run via an interpreter, and 
> therefore wants to be executable, rather than limiting to just env and 
> specific shells.

Also, many maintainers already have scripts/checkpatch.pl as a git 
pre-commit hook, and putting the check in checkpatch.pl means that 
patchew would also flag the issue.
Laurent Vivier Oct. 25, 2018, 1:57 p.m. UTC | #6
On 04/10/2018 17:18, Cleber Rosa wrote:
> Commit 990dc39c made all tests executable at the time, but 218 came in
> later, and missing those permissions.
> 
> Signed-off-by: Cleber Rosa <crosa@redhat.com>
> ---
>  tests/qemu-iotests/218 | 0
>  1 file changed, 0 insertions(+), 0 deletions(-)
>  mode change 100644 => 100755 tests/qemu-iotests/218
> 
> diff --git a/tests/qemu-iotests/218 b/tests/qemu-iotests/218
> old mode 100644
> new mode 100755
> 

Applied

Thanks,
Laurent
Eduardo Habkost Oct. 26, 2018, 3:27 p.m. UTC | #7
On Thu, Oct 04, 2018 at 12:18:42PM -0400, Cleber Rosa wrote:
> Just a collection of trivial fixes and clean ups that have been lying
> around here for some time.

I'm queueing patches 07-10 on python-next.  I'm aware that
Laurent already queued some of them (thanks!), but I want to
avoid conflicts in case other patches touching these modules are
queued on python-next.