On Sun, Dec 15, 2019 at 09:17:57PM +0100, Johannes Schindelin wrote: > Hi Emily, > > On Thu, 12 Dec 2019, Emily Shaffer wrote: > > > diff --git a/generate-bugreport-config-safelist.sh b/generate-bugreport-config-safelist.sh > > new file mode 100755 > > index 0000000000..06b8e0c3c4 > > --- /dev/null > > +++ b/generate-bugreport-config-safelist.sh > > @@ -0,0 +1,22 @@ > > +#!/bin/sh > > + > > +cat <<EOF > > +/* Automatically generated by bugreport-generate-config-safelist.sh */ > > + > > + > > +static const char *bugreport_config_safelist[] = { > > +EOF > > + > > +# cat all regular files in Documentation/config > > +find Documentation/config -type f -exec cat {} \; | > > +# print the command name which matches the bugreport-include macro > > +sed -n 's/^\(.*\) \+bugreport:include.* ::$/\1/p' | > > If you use `/ "\1",/` as replacement, you can totally avoid that ugly > `while` loop (that is unfortunately quite slow in MSYS2/Cygwin). You can > still pipe the result into `sort` just the same. Oooof. How embarrassing - I will do that.