Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simple script to add characters. Added P&P characters.
- Loading branch information
Dave Cross
committed
Oct 2, 2015
1 parent
163ed4e
commit 2f2dfcb
Showing
4 changed files
with
50 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/usr/bin/perl | ||
|
||
use strict; | ||
use warnings; | ||
use FindBin '$Bin'; | ||
use lib "$Bin/../Literature/lib"; | ||
use 5.010; | ||
|
||
use Literature::Schema; | ||
|
||
my $sch = Literature::Schema->get_schema; | ||
|
||
my $work_rs = $sch->resultset('Work'); | ||
my $pp = $work_rs->find({ title => 'Pride and Prejudice' }); | ||
|
||
while (<DATA>) { | ||
chomp; | ||
$pp->add_to_fictional_characters({ name => $_ }); | ||
} | ||
|
||
__DATA__ | ||
Mr Bennet | ||
Mrs Bennet | ||
Jane Bennet | ||
Mary Bennet | ||
Catherine Bennet | ||
Lydia Bennet | ||
Charles Bingley | ||
Caroline Bingley | ||
George Wickham | ||
William Collins | ||
Lady Catherine de Bourgh |