Skip to content

Commit

Permalink
Replace egrep with grep -E
Browse files Browse the repository at this point in the history
For the GNU Grep package version >= 3.8, the `egrep` command emits:
```
egrep: warning: egrep is obsolescent; using grep -E
```
which makes the `./autogen.sh` script very noisy.
  • Loading branch information
hebasto authored and bluca committed Aug 26, 2023
1 parent ec013f3 commit de5ee18
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Jenkinsfile
Expand Up @@ -443,7 +443,7 @@ pipeline {
echo "Used: myDEPLOY_JOB_NAME:${myDEPLOY_JOB_NAME} myDEPLOY_BRANCH_PATTERN:${myDEPLOY_BRANCH_PATTERN} myDEPLOY_REPORT_RESULT:${myDEPLOY_REPORT_RESULT}"
if ( (myDEPLOY_JOB_NAME != "") && (myDEPLOY_BRANCH_PATTERN != "") ) {
if ( env.BRANCH_NAME =~ myDEPLOY_BRANCH_PATTERN ) {
def GIT_URL = sh(returnStdout: true, script: """git remote -v | egrep '^origin' | awk '{print \$2}' | head -1""").trim()
def GIT_URL = sh(returnStdout: true, script: """git remote -v | grep -E '^origin' | awk '{print \$2}' | head -1""").trim()
def GIT_COMMIT = sh(returnStdout: true, script: 'git rev-parse --verify HEAD').trim()
def DIST_ARCHIVE = ""
if ( params.DO_DIST_DOCS ) { DIST_ARCHIVE = env.BUILD_URL + "artifact/__dist.tar.gz" }
Expand Down
4 changes: 2 additions & 2 deletions builds/zos/runtests
Expand Up @@ -63,9 +63,9 @@ SKIP_TESTS="test_.*_tipc"
#
# Excluding tests we know will fail because of missing functionality
#
noinst_PROGRAMS=$(grep "test_" Makefile.am | egrep -v "_SOURCES|XFAIL" |
noinst_PROGRAMS=$(grep "test_" Makefile.am | grep -E -v "_SOURCES|XFAIL" |
sed 's/noinst_PROGRAMS.* test/test/; s/^ *//; s/ *\\ *$//;' |
grep -v "${SKIP_TESTS}" | egrep -v "${XFAIL_TESTS}")
grep -v "${SKIP_TESTS}" | grep -E -v "${XFAIL_TESTS}")
#echo "Found tetsts: ${noinst_PROGRAMS}"

# Run tests on command line, or all tests we found
Expand Down
6 changes: 3 additions & 3 deletions version.sh
Expand Up @@ -7,9 +7,9 @@ if [ ! -f include/zmq.h ]; then
echo "version.sh: error: include/zmq.h does not exist" 1>&2
exit 1
fi
MAJOR=`egrep '^#define +ZMQ_VERSION_MAJOR +[0-9]+$' include/zmq.h`
MINOR=`egrep '^#define +ZMQ_VERSION_MINOR +[0-9]+$' include/zmq.h`
PATCH=`egrep '^#define +ZMQ_VERSION_PATCH +[0-9]+$' include/zmq.h`
MAJOR=`grep -E '^#define +ZMQ_VERSION_MAJOR +[0-9]+$' include/zmq.h`
MINOR=`grep -E '^#define +ZMQ_VERSION_MINOR +[0-9]+$' include/zmq.h`
PATCH=`grep -E '^#define +ZMQ_VERSION_PATCH +[0-9]+$' include/zmq.h`
if [ -z "$MAJOR" -o -z "$MINOR" -o -z "$PATCH" ]; then
echo "version.sh: error: could not extract version from include/zmq.h" 1>&2
exit 1
Expand Down

0 comments on commit de5ee18

Please sign in to comment.