Merge pull request #100662 from NeQuissimus/bash_50p18

bash: 5.0p17 -> 5.0p18
This commit is contained in:
Tim Steinbach 2020-10-16 16:01:51 -04:00 committed by GitHub
commit b4586ea432
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 4 deletions

View File

@ -18,4 +18,5 @@ patch: [
(patch "015" "0pm0px758w4i23s55wajcv6lqfiym7zgxvq0pxf6vclkv8nxy5x5")
(patch "016" "0vdha332km2iwx8g2ld15jy7d24cbplzgr1531dpzylr9ajxglgz")
(patch "017" "0cfw5lz3fcvq9h1fxihxvw940fjk68015jazvl8x8rlazgxbkwsc")
(patch "018" "1lw1vv0aj6x254hgx4klbz8qkvwxif0g6i7dx116cnhhb8vlwcbw")
]

View File

@ -1,4 +1,5 @@
#!/bin/sh
#!/usr/bin/env nix-shell
#!nix-shell --pure -i bash -p wget -p gnupg -p cacert
# Update patch set for GNU Bash or Readline.
@ -14,8 +15,6 @@ fi
PROJECT="$1"
VERSION="$2"
VERSION_CONDENSED="$(echo $VERSION | sed -es/\\.//g)"
GPG="$(if $(type -P gpg2 > /dev/null); then echo gpg2; else echo gpg; fi)"
PATCH_LIST="$PROJECT-$VERSION-patches.nix"
set -e
@ -25,6 +24,12 @@ end=100 # must be > 99 for correct padding
rm -vf "$PATCH_LIST"
wget "https://tiswww.case.edu/php/chet/gpgkey.asc"
echo "4ef5051ce7200241e65d29c11eb57df8 gpgkey.asc" > gpgkey.asc.md5
md5sum -c gpgkey.asc.md5
gpg --import ./gpgkey.asc
rm gpgkey.asc{,.md5}
( echo "# Automatically generated by \`$(basename $0)'; do not edit." ; \
echo "" ; \
echo "patch: [" ) \
@ -34,7 +39,7 @@ for i in `seq -w $start $end`
do
wget ftp.gnu.org/gnu/$PROJECT/$PROJECT-$VERSION-patches/$PROJECT$VERSION_CONDENSED-$i || break
wget ftp.gnu.org/gnu/$PROJECT/$PROJECT-$VERSION-patches/$PROJECT$VERSION_CONDENSED-$i.sig
"$GPG" --verify $PROJECT$VERSION_CONDENSED-$i.sig
gpg --verify $PROJECT$VERSION_CONDENSED-$i.sig
echo "(patch \"$i\" \"$(nix-hash --flat --type sha256 --base32 $PROJECT$VERSION_CONDENSED-$i)\")" \
>> "$PATCH_LIST"