scripts/update-abilist.sh: Accept empty list of files to patch
diff mbox series

Message ID 20180530130332.9E060415488E6@oldenburg.str.redhat.com
State New
Headers show
Series
  • scripts/update-abilist.sh: Accept empty list of files to patch
Related show

Commit Message

Florian Weimer May 30, 2018, 1:03 p.m. UTC
Commit b289cd9db8286fa6c670104dd5dfcfc68d5d00d6 (“Ignore absolute
symbols in ABI tests.”) broke “make update-all-abi” because an empty
list of files is now passed to scripts/update-abilist.sh.

2018-05-30  Florian Weimer  <fweimer@redhat.com>

	* scripts/update-abilist.sh: Accept empty list of files to patch.

Comments

Florian Weimer June 13, 2018, 8:41 p.m. UTC | #1
* Florian Weimer:

> Commit b289cd9db8286fa6c670104dd5dfcfc68d5d00d6 (“Ignore absolute
> symbols in ABI tests.”) broke “make update-all-abi” because an empty
> list of files is now passed to scripts/update-abilist.sh.
>
> 2018-05-30  Florian Weimer  <fweimer@redhat.com>
>
> 	* scripts/update-abilist.sh: Accept empty list of files to patch.
>
> diff --git a/scripts/update-abilist.sh b/scripts/update-abilist.sh
> index 68d469b3e5..28953bfe28 100644
> --- a/scripts/update-abilist.sh
> +++ b/scripts/update-abilist.sh
> @@ -20,9 +20,12 @@
>  set -e
>  export LC_ALL=C
>  
> -if [ $# -lt 3 ]; then
> +if [ $# -lt 2 ]; then
>    echo "usage: $0 OLD-FILE NEW-FILE FILES-TO-BE-PATCHED..." 1>&2
>    exit 2
> +elif [ $# -eq 2 ]; then
> +  echo "info: no files to patch" 1>&2
> +  exit 0
>  fi
>  
>  old_file="$1"

Ping?
Adhemerval Zanella June 13, 2018, 9:36 p.m. UTC | #2
On 13/06/2018 17:41, Florian Weimer wrote:
> * Florian Weimer:
> 
>> Commit b289cd9db8286fa6c670104dd5dfcfc68d5d00d6 (“Ignore absolute
>> symbols in ABI tests.”) broke “make update-all-abi” because an empty
>> list of files is now passed to scripts/update-abilist.sh.
>>
>> 2018-05-30  Florian Weimer  <fweimer@redhat.com>
>>
>> 	* scripts/update-abilist.sh: Accept empty list of files to patch.
>>
>> diff --git a/scripts/update-abilist.sh b/scripts/update-abilist.sh
>> index 68d469b3e5..28953bfe28 100644
>> --- a/scripts/update-abilist.sh
>> +++ b/scripts/update-abilist.sh
>> @@ -20,9 +20,12 @@
>>  set -e
>>  export LC_ALL=C
>>  
>> -if [ $# -lt 3 ]; then
>> +if [ $# -lt 2 ]; then
>>    echo "usage: $0 OLD-FILE NEW-FILE FILES-TO-BE-PATCHED..." 1>&2
>>    exit 2
>> +elif [ $# -eq 2 ]; then
>> +  echo "info: no files to patch" 1>&2
>> +  exit 0
>>  fi
>>  
>>  old_file="$1"
> 
> Ping?
> 

LGTM, thanks.

Patch
diff mbox series

diff --git a/scripts/update-abilist.sh b/scripts/update-abilist.sh
index 68d469b3e5..28953bfe28 100644
--- a/scripts/update-abilist.sh
+++ b/scripts/update-abilist.sh
@@ -20,9 +20,12 @@ 
 set -e
 export LC_ALL=C
 
-if [ $# -lt 3 ]; then
+if [ $# -lt 2 ]; then
   echo "usage: $0 OLD-FILE NEW-FILE FILES-TO-BE-PATCHED..." 1>&2
   exit 2
+elif [ $# -eq 2 ]; then
+  echo "info: no files to patch" 1>&2
+  exit 0
 fi
 
 old_file="$1"