summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--trunk/src/echangelog/ChangeLog5
-rw-r--r--trunk/src/echangelog/echangelog4
2 files changed, 7 insertions, 2 deletions
diff --git a/trunk/src/echangelog/ChangeLog b/trunk/src/echangelog/ChangeLog
index b079e53..8d64da2 100644
--- a/trunk/src/echangelog/ChangeLog
+++ b/trunk/src/echangelog/ChangeLog
@@ -1,3 +1,8 @@
+15 Sep 2004 Aron Griffis <agriffis@gentoo.org>
+ * fix the wrapping to fit in 80 columns properly. It was
+ previously possible to get lines with 81 chars. Thanks to
+ ciaranm for reporting.
+
29 Mar 2004 Aron Griffis <agriffis@gentoo.org>
* fix bug 46111 by testing for /<root@/ instead of / root@/
diff --git a/trunk/src/echangelog/echangelog b/trunk/src/echangelog/echangelog
index 3a8c3c5..9c37285 100644
--- a/trunk/src/echangelog/echangelog
+++ b/trunk/src/echangelog/echangelog
@@ -15,7 +15,7 @@ use POSIX qw(strftime getcwd setlocale);
setlocale(&POSIX::LC_ALL, "C");
use Text::Wrap;
-$Text::Wrap::columns = 79;
+$Text::Wrap::columns = 77;
$Text::Wrap::unexpand = 0;
# Global variables
@@ -154,7 +154,7 @@ if ($ARGV[0]) {
die "Empty entry; aborting\n" unless $input =~ /\S/;
# If there are any long lines, then wrap the input at $columns chars
-# (leaving 2 chars on each end after adding indentation below).
+# (leaving 2 chars on left, one char on right, after adding indentation below).
$input =~ s/^\s*(.*?)\s*\z/$1/s; # trim whitespace
$input = Text::Wrap::fill('', '', $input) if ($input =~ /^.{80}/m);
$input =~ s/^/ /gm; # add indentation