summaryrefslogtreecommitdiff
path: root/.git-hooks
diff options
context:
space:
mode:
authorRene Engelhard <rene@debian.org>2022-09-07 21:34:42 +0200
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2022-09-08 14:43:53 +0200
commitfd42cea5f301a10cdeaa29959f04b111de534132 (patch)
tree0bfa9e9f22d63dcbb6eeafc6002752d9ff20399e /.git-hooks
parent09e499e64ec4acb24c9524c8aacabc6182124442 (diff)
replace egrep/fgrep calls with grep -E/grep -F
as egrep/fgrep is deprecated since long amd grep 3.8+ now actually warns (e.g. "egrep: warning: egrep is obsolescent; using grep -E") Change-Id: I5b10f05dffdd09081deb05cef974e3cdb2907315 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139614 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
Diffstat (limited to '.git-hooks')
-rwxr-xr-x.git-hooks/commit-msg4
1 files changed, 2 insertions, 2 deletions
diff --git a/.git-hooks/commit-msg b/.git-hooks/commit-msg
index eebca62cb6f7..950a6b709d9a 100755
--- a/.git-hooks/commit-msg
+++ b/.git-hooks/commit-msg
@@ -49,8 +49,8 @@ if [ "$len" -gt 79 ] ; then
fi
fdo_regex='fdo#[0-9]+'
-if egrep -q "$fdo_regex" $1; then
- for bugid in `head -n 1 $1 |egrep -o "$fdo_regex" |sed 's/fdo#//'`
+if grep -E -q "$fdo_regex" $1; then
+ for bugid in `head -n 1 $1 | grep -E -o "$fdo_regex" |sed 's/fdo#//'`
do
if [ "`echo $bugid |sed 's/fdo#//'`" -gt 88775 ]; then
abort "$1" "The first line contains a suspicious fdo# rereference: 'fdo#$bugid', did you mean tdf#?"