app-admin/rsyslog: bash syntax tidy
authorGöktürk Yüksek <gokturk@gentoo.org>
Sat, 21 May 2016 17:33:53 +0000 (13:33 -0400)
committerIan Delaney <idella4@gentoo.org>
Mon, 23 May 2016 11:32:47 +0000 (19:32 +0800)
replace POSIX '[' with the bash '[[' in 8.18.0

Package-Manager: portage-2.2.28
Closes: https://github.com/gentoo/gentoo/pull/1511

Signed-off-by: Ian Delaney <idella4@gentoo.org>
app-admin/rsyslog/rsyslog-8.18.0.ebuild

index 6e00e29b9dd5c0b89b1b725dc065497145f81d7c..5e00e6bf96bac7f18f91b4235c38210e6a5c61f3 100644 (file)
@@ -121,7 +121,7 @@ src_unpack() {
        if use doc; then
                if [[ ${PV} == "9999" ]]; then
                        local _EGIT_BRANCH=
-                       if [ -n "${EGIT_BRANCH}" ]; then
+                       if [[ -n "${EGIT_BRANCH}" ]]; then
                                # Cannot use rsyslog commits/branches for documentation repository
                                _EGIT_BRANCH=${EGIT_BRANCH}
                                unset EGIT_BRANCH
@@ -130,7 +130,7 @@ src_unpack() {
                        git-r3_fetch "${DOC_REPO_URI}"
                        git-r3_checkout "${DOC_REPO_URI}" "${S}"/docs
 
-                       if [ -n "${_EGIT_BRANCH}" ]; then
+                       if [[ -n "${_EGIT_BRANCH}" ]]; then
                                # Restore previous EGIT_BRANCH information
                                EGIT_BRANCH=${_EGIT_BRANCH}
                        fi
@@ -269,7 +269,7 @@ src_test() {
        if ! emake --jobs 1 check; then
                eerror "Test suite failed! :("
 
-               if [ -z "${_has_increased_ulimit}" ]; then
+               if [[ -z "${_has_increased_ulimit}" ]]; then
                        eerror "Probably because open file limit couldn't be set to 3072."
                fi
 
@@ -376,13 +376,13 @@ pkg_config() {
 
        # Make sure the certificates directory exists
        local CERTDIR="${EROOT}/etc/ssl/${PN}"
-       if [ ! -d "${CERTDIR}" ]; then
+       if [[ ! -d "${CERTDIR}" ]]; then
                mkdir "${CERTDIR}" || die
        fi
        einfo "Your certificates will be stored in ${CERTDIR}"
 
        # Create a default CA if needed
-       if [ ! -f "${CERTDIR}/${PN}_ca.cert.pem" ]; then
+       if [[ ! -f "${CERTDIR}/${PN}_ca.cert.pem" ]]; then
                einfo "No CA key and certificate found in ${CERTDIR}, creating them for you..."
                certtool --generate-privkey \
                        --outfile "${CERTDIR}/${PN}_ca.privkey.pem" &>/dev/null