#!/usr/bin/perl -w # Extract author information from C++ files # and print it out in DocBook format as a list # Daniel Naber # $Id$ my $file = $ARGV[0]; if( ! $file ) { print "Usage: $0 \n"; exit; } open(IN, $file) || die "Cannot open '$file': $!\n"; undef $/; my $str = (); close(IN); print "\n"; while( $str =~ m/addAuthor\s*\(\s*"(.*?)",\s*.*?,\s*"(.*?)"/gs ) { my ($name, $email) = ($1, $2); print "$name $email\n"; #print "$name, $email\n"; } print "\n"; print STDERR "Warning: maybe you need to fix umlauts manually...\n"; exit;