aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS4
-rwxr-xr-xmonitor-edid7
2 files changed, 8 insertions, 3 deletions
diff --git a/NEWS b/NEWS
index 0288879..cb419ee 100644
--- a/NEWS
+++ b/NEWS
@@ -33,6 +33,10 @@
multiple methods
o allow retrieval of multiple EDIDs via VBE
+- monitor-edid:
+ o add --first support for stopping processing after one EDID has been
+ found
+
Version 2.5 - 18 October 2009, by Anssi Hannula
- monitor-probe-using-X:
diff --git a/monitor-edid b/monitor-edid
index 4133082..a59226f 100755
--- a/monitor-edid
+++ b/monitor-edid
@@ -32,12 +32,12 @@ if ($0 =~ /monitor-get-edid/) {
exit 1;
}
} else {
- GetOptions_(@common_options, 'MonitorsDB', 'perl')
- or die "usage: monitor-edid $common_options_usage [--perl] [--MonitorsDB]\n";
+ GetOptions_(@common_options, 'first', 'MonitorsDB', 'perl')
+ or die "usage: monitor-edid $common_options_usage [--first] [--perl] [--MonitorsDB]\n";
my $err = 1;
- if (my @edids = get_edids()) {
+ if (my @edids = get_edids($opt{first})) {
print "(\n" if $opt{perl};
foreach (@edids) {
my ($f, $edid) = @$_;
@@ -99,6 +99,7 @@ sub get_edids {
next if grep { $_->[1] eq $edid } @l;
push @l, [ "vbe$port" => $edid ];
+ last if $b_get_first;
}
}
}