diff --git a/perl/Gnome-Tomboy/tom b/perl/Gnome-Tomboy/tom index 806f8a2c3bf16ce28e3c2c50880efd16fa142d1f..ff915b9f83ff6e996d9e8907c9cff765b8df95b8 100755 --- a/perl/Gnome-Tomboy/tom +++ b/perl/Gnome-Tomboy/tom @@ -58,6 +58,7 @@ my ($note_dir)= Tomboy::paths(); my $start_tb= 0; my $start_visual_editor= 0; # AKA $EDITOR my $dump_note= 0; +my $verbosity= 'dump'; my $toc; my $op_code; my @PAR; @@ -89,6 +90,7 @@ while (my $arg= shift (@ARGV)) { if ($a eq 'd') { $note_dir= shift (@ARGV); $note_dir_changed= 1; } elsif ($a eq 't') { $toc_file= shift (@ARGV); } + elsif ($a eq 'T') { $verbosity= 'title'; } elsif ($a eq 'e') { $start_tb= 1; } elsif ($a eq 'v') { $start_visual_editor= 1; } elsif ($a eq 'D') { $dump_note= 1; } @@ -185,8 +187,11 @@ sub find_note foreach my $res (@res) { $uuid{$res->{'uuid'}}= $res; } # TODO: count hits } + print '='x72, "\n"; foreach my $uuid (keys %uuid) { + my $rec= $uuid{$uuid}; + if ($start_tb) { my @par= ('uuid' => $uuid); @@ -202,11 +207,18 @@ sub find_note } elsif ($dump_note) { - dump_note($uuid{$uuid}->{'fnm'}); + dump_note($rec->{'fnm'}); } else { - print Dumper ($uuid{$uuid}); + if ($verbosity eq 'title') + { + print $rec->{'title'}, "\n"; + } + else + { + print Dumper ($rec); + } } } }