This is an automated email from the ASF dual-hosted git repository.
sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git
The following commit(s) were added to refs/heads/master by this push:
new 1cb7014 Only fix lines that appear to be in the correct section
1cb7014 is described below
commit 1cb70140cf2344c3b8020d2c51db882b6180eee2
Author: Sebb <[email protected]>
AuthorDate: Thu Apr 18 10:46:10 2019 +0100
Only fix lines that appear to be in the correct section
---
tools/toccomments.sh | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/tools/toccomments.sh b/tools/toccomments.sh
index 021f1cb..d62deb6 100755
--- a/tools/toccomments.sh
+++ b/tools/toccomments.sh
@@ -3,7 +3,8 @@
# Fix incorrectly wrapped comments in Incubator ToC section
# Intended for use on archived agendas and published minutes.
-# Look for Comments: preceeded by non-space
-ruby -p -i -e 'gsub(/(\S)\s+(Comments:)/,"\\1\n \\2")' "$@"
+# Look for Comments: preceeded by non-space if line contains e.g. [ ](batchee)
+# N.B. there are some minutes with '[](...)' and some with '[ ] (..)'
+ruby -p -i -e 'gsub(/(\S)\s+(Comments:)/,"\\1\n \\2") if /^ +\[.?\]
?\(\S+\) /' "$@"
# no need to save original files as tool is intended for use with files in
SVN/Git
-echo "Done; the updated files can be diffed/checked in as required"
\ No newline at end of file
+echo "Done; the updated files can be diffed/checked in as required"