Skip to content

Commit

Permalink
Handle with stopword path
Browse files Browse the repository at this point in the history
  • Loading branch information
Lucie Dubrunfaut authored and Lucie Dubrunfaut committed Jan 18, 2024
1 parent e9ec918 commit d474fc6
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions .github/scripts/pod_spell_check.t
Original file line number Diff line number Diff line change
@@ -1,13 +1,22 @@
use strict;
use warnings;
use Test::More;

use Test::More;
use Test::Spelling;

open(FILE, "<", "stopwords.t");
add_stopwords(<FILE>);
if (!@ARGV) {
die "Missing perl file to check.";
}

set_spell_cmd('hunspell -l');
all_pod_files_spelling_ok( $ARGV[0]);
my $stopword_filename='.github/scripts/stopwords.t';
if(defined($ARGV[1])){
$stopword_filename=$ARGV[1];
}
open(FILE, "<", $stopword_filename)
or die "Could not open $stopword_filename";
printf("stopword file use : ".$stopword_filename." \n");

add_stopwords(<FILE>);
set_spell_cmd('hunspell -l');
all_pod_files_spelling_ok($ARGV[0]);
close(FILE);

0 comments on commit d474fc6

Please sign in to comment.