badwords: pass config as filename arg

Instead of stdin.

To simplify the command-line, and allow using a safe and portable
`system()` call from `badwords-all`.

Ref: https://perldoc.perl.org/functions/system

Closes #20970
This commit is contained in:
Viktor Szakats 2026-03-18 00:51:08 +01:00
parent 3f06e27502
commit 650b33a3db
No known key found for this signature in database
2 changed files with 7 additions and 3 deletions

View file

@ -8,6 +8,7 @@ use warnings;
use File::Basename;
chdir dirname(__FILE__) . "/..";
chdir dirname(__FILE__) . '/..';
exit system("scripts/badwords '**.md' projects/OS400/README.OS400 src lib include docs/examples < scripts/badwords.txt") >> 8;
exit system('scripts/badwords', ('scripts/badwords.txt',
'**.md', 'projects/OS400/README.OS400', 'src', 'lib', 'include', 'docs/examples')) >> 8;