5 BEGIN { push @INC, '.' }
7 use open ':std' => ':encoding(utf-8)';
8 my $db = Shiar_Sheet::DB->connect;
14 my $lang = shift @ARGV or die "Missing language\n";
16 my %filter = (lang => $lang);
17 my $cols = "ref, array_to_string(form || alt, '/'), prio, id, sub";
18 %rows = $db->select(_word => $cols, \%filter)->map_arrays;
19 defined $_->[-1] or pop @$_ for values %rows;
22 [$db->select(word => 'id', {cat => undef, ref => undef})->flat]
25 =~ s/\\x\{([0-9A-F]+)\}/chr hex $1/ger;