From 0dcb175c42f0b6ff61c3438cbae5f0b7fd87eea6 Mon Sep 17 00:00:00 2001 From: Jeremy Stanley Date: Tue, 13 Oct 2015 18:01:09 +0000 Subject: [PATCH] Clean up doubled backslashes in logrotate config According to https://docs.puppetlabs.com/puppet/3.8/reference/lang_datatypes.html there is no way to end a single-quoted string with a literal backslash, so fold this content into the preceding double-quoted string in an effort to satisfy the linter as well. Change-Id: Ic639cd2fc1c7953cbf4311ce7c958f9bdb61e31b --- manifests/logrotate.pp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/manifests/logrotate.pp b/manifests/logrotate.pp index c9bad6d..7418782 100644 --- a/manifests/logrotate.pp +++ b/manifests/logrotate.pp @@ -12,13 +12,11 @@ class httpd::logrotate ( ], $prerotate = [ "if [ -d /etc/logrotate.d/${::httpd::params::apache_name}-prerotate ]; then \\", - " run-parts /etc/logrotate.d/${::httpd::params::apache_name}-prerotate; \\", - 'fi; \\', + " run-parts /etc/logrotate.d/${::httpd::params::apache_name}-prerotate; fi ; \\", ], $postrotate = [ - "if service ${::httpd::params::apache_name} status > /dev/null ; then \\", - " service ${::httpd::params::apache_name} reload > /dev/null; \\", - 'fi; \\', + "if service ${::httpd::params::apache_name} status > /dev/null; then \\", + " service ${::httpd::params::apache_name} reload > /dev/null; fi; \\", ], $firstaction = 'undef', $lastaction = 'undef',