Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100755 26 lines (23 sloc) 0.39 kb
e2b3ed3 @cmungall new
authored
1 #!/usr/bin/perl
2
3 while (<>) {
4 chomp;
5 s/\!.*//;
6 s/^\s+//;
7 s/\s+$//;
8 next unless $_;
9 if (/(\S+:\S+)\s+(.*)/) {
10 print_term($1,$2);
11 }
12 elsif (/(\S+)\s+(.*)/) {
13 print_term($1,$2);
14 }
15 else {
16 warn("Cannot parse: $_");
17 }
18 }
19 exit 0;
20
21 sub print_term {
22 my $id = shift;
23 my $n = shift;
24 print "[Term]\nid: $id\nname: $n\n\n"
25 }
Something went wrong with that request. Please try again.