Using the
Gedcom modules, i made a quick ASCII decscendency chart. I grabbed a freely available royal family GEDCOM file. Here's what it produced:
C:\>perl dchart.pl royal.ged "Elizabeth"
1 [I0001] Elizabeth Alexandra Mary Windsor (April 21st, 1926)
+ [I0002] Philip Mountbatten (1921)
2 [I0006] Charles Philip Arthur George Windsor (November 14th,
+ 1948)
+ [I0010] Diana Spencer (July 1st, 1961 - August 31st, 1997)
3 [I0011] William
3 [I0012] Harry
2 [I0007] Anne Elizabeth Alice Louise (August 15th, 1950)
+ [I0033] mark Phillips
3 [I0034] Zara
3 [I0035] (male)
2 [I0008] Andrew Albert Christian Edward (February 19th, 1960
+)
2 [I0009] Edward Antony Richard Louis (March 10th, 1964)
use strict;
use Gedcom;
die 'ERROR: No file specified' unless $ARGV[0];
die 'ERROR: File not found' unless -e $ARGV[0];
die 'ERROR: No name specified' unless $ARGV[1];
my $ged = Gedcom->new(gedcom_file => $ARGV[0], read_only => 1) or die
+"ERROR: $!";
die 'ERROR: No matches found.' unless my $i = $ged->get_individual($AR
+GV[1]);
descendency($i);
sub descendency {
my $i = shift;
my $gen = shift || 1;
print "\t" x ($gen - 1), "$gen ", info($i), "\n";
foreach my $s ($i->spouse) {
print "\t" x ($gen - 1), '+ ', info($s), "\n";
descendency($_, $gen + 1) for ($s->children);
}
}
sub info {
my $i = shift;
return '[' . $i->xref . '] ' . names($i) . ' ' . dates($i);
}
sub dates {
my $i = shift;
$i->normalise_dates("%B %E, %Y");
my $r = '(' . join(' - ', ($i->get_value('birth date'), $i->get_va
+lue('death date'))) . ')';
return $r eq '()' ? '' : $r;
}
sub names {
my $i = shift;
return $i->given_names . ' ' . $i->surname;
}