[Pkg-apache-commits] [SCM] Debian packaging for apache2 (Apache HTTPD 2.x) branch, next, updated. c2896e13ae967be5c1e0d04acd74b78ea8124025
Stefan Fritsch
sf at sfritsch.de
Sat Mar 31 21:19:38 UTC 2012
The following commit has been merged in the next branch:
commit 07daea46c5cb2eff8691f1597ddeb6e153bf42c7
Author: Stefan Fritsch <sf at sfritsch.de>
Date: Sat Mar 31 22:39:31 2012 +0200
replace some use of sed with shell constructs
diff --git a/debian/debhelper/apache2-maintscript-helper b/debian/debhelper/apache2-maintscript-helper
index fa8ae06..cdf2765 100644
--- a/debian/debhelper/apache2-maintscript-helper
+++ b/debian/debhelper/apache2-maintscript-helper
@@ -31,8 +31,7 @@ else
return 1
fi
- APACHE2_MAINTSCRIPT_NAME="$0"
- APACHE2_MAINTSCRIPT_NAME=$(echo "$APACHE2_MAINTSCRIPT_NAME" | sed -re 's#^.*?\.(\w+)#\1#' )
+ APACHE2_MAINTSCRIPT_NAME="${0##*.}"
case "$APACHE2_MAINTSCRIPT_NAME" in
preinst|prerm|postrm|postinst)
# yay - recognized script
@@ -43,8 +42,8 @@ else
;;
esac
- APACHE2_MAINTSCRIPT_PACKAGE="$0"
- APACHE2_MAINTSCRIPT_PACKAGE=$(echo "$APACHE2_MAINTSCRIPT_PACKAGE" | sed -re 's#^.+/(.*)\.\w+$#\1#' )
+ APACHE2_MAINTSCRIPT_PACKAGE="${0##*/}"
+ APACHE2_MAINTSCRIPT_PACKAGE="${APACHE2_MAINTSCRIPT_PACKAGE%.*}"
APACHE2_MAINTSCRIPT_METHOD="$1"
APACHE2_MAINTSCRIPT_ARGUMENT="$2"
@@ -202,7 +201,7 @@ apache2_switch_mpm()
[ -x /usr/sbin/a2enmod ] || return 1
local MPM="$1"
- MPM=$(echo "$MPM" | sed -e 's/^mpm_//')
+ MPM="${MPM#mpm_}"
if ! apache2_needs_action ; then
--
Debian packaging for apache2 (Apache HTTPD 2.x)
More information about the Pkg-apache-commits
mailing list