Skip to content

Commit 19e5e5e

Browse files
badboyantirez
authored andcommitted
Don't use extended Regexp Syntax
It's not POSIX (BSD systems have -E instead) and we don't actually need it. Closes #1922
1 parent 6247421 commit 19e5e5e

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

utils/install_server.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -168,13 +168,13 @@ fi
168168
echo "## Generated by install_server.sh ##" > $TMP_FILE
169169

170170
read -r SED_EXPR <<-EOF
171-
s#^port [0-9]{4}\$#port ${REDIS_PORT}#; \
172-
s#^logfile .+\$#logfile ${REDIS_LOG_FILE}#; \
173-
s#^dir .+\$#dir ${REDIS_DATA_DIR}#; \
174-
s#^pidfile .+\$#pidfile ${PIDFILE}#; \
175-
s#^daemonize no\$#daemonize yes#;
171+
s#^port .\+#port ${REDIS_PORT}#; \
172+
s#^logfile .\+#logfile ${REDIS_LOG_FILE}#; \
173+
s#^dir .\+#dir ${REDIS_DATA_DIR}#; \
174+
s#^pidfile .\+#pidfile ${PIDFILE}#; \
175+
s#^daemonize no#daemonize yes#;
176176
EOF
177-
sed -r "$SED_EXPR" $DEFAULT_CONFIG >> $TMP_FILE
177+
sed "$SED_EXPR" $DEFAULT_CONFIG >> $TMP_FILE
178178

179179
#cat $TPL_FILE | while read line; do eval "echo \"$line\"" >> $TMP_FILE; done
180180
cp $TMP_FILE $REDIS_CONFIG_FILE || die "Could not write redis config file $REDIS_CONFIG_FILE"

0 commit comments

Comments
 (0)