word: move inline make scripts to distinct tools
[sheet.git] / tools / wordpairs
diff --git a/tools/wordpairs b/tools/wordpairs
new file mode 100755 (executable)
index 0000000..9ba87f4
--- /dev/null
@@ -0,0 +1,13 @@
+#!/usr/bin/env perl
+use 5.014;
+use warnings;
+use lib '.';
+use Shiar_Sheet::DB;
+use Data::Dump 'pp';
+
+my $db = Shiar_Sheet::DB->connect;
+my $query = $db->select(
+       'word w JOIN word a ON w.id = a.ref' => 'w.id, a.id',
+       {'a.lang' => undef}
+);
+say pp($query->map or exit 1);