From owner-svn-src-stable-10@freebsd.org Tue May 30 16:09:56 2017 Return-Path: Delivered-To: svn-src-stable-10@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0A633B828A0; Tue, 30 May 2017 16:09:56 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BE7DD6A0B6; Tue, 30 May 2017 16:09:55 +0000 (UTC) (envelope-from asomers@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4UG9saC006438; Tue, 30 May 2017 16:09:54 GMT (envelope-from asomers@FreeBSD.org) Received: (from asomers@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4UG9s3o006436; Tue, 30 May 2017 16:09:54 GMT (envelope-from asomers@FreeBSD.org) Message-Id: <201705301609.v4UG9s3o006436@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: asomers set sender to asomers@FreeBSD.org using -f From: Alan Somers Date: Tue, 30 May 2017 16:09:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r319221 - in stable/10/etc/periodic: daily monthly weekly X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-10@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for only the 10-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 30 May 2017 16:09:56 -0000 Author: asomers Date: Tue May 30 16:09:54 2017 New Revision: 319221 URL: https://svnweb.freebsd.org/changeset/base/319221 Log: MFC r313069: Allow 999.local to run scripts in any language If one of the scripts listed in (daily|weekly|monthly)_local is executable, 999.local should simply execute it. Only if the script isn't executable should 999.local assume it needs /bin/sh. Reviewed by: brian Sponsored by: Spectra Logic Corp Modified: stable/10/etc/periodic/daily/999.local stable/10/etc/periodic/monthly/999.local stable/10/etc/periodic/weekly/999.local Directory Properties: stable/10/ (props changed) Modified: stable/10/etc/periodic/daily/999.local ============================================================================== --- stable/10/etc/periodic/daily/999.local Tue May 30 16:05:11 2017 (r319220) +++ stable/10/etc/periodic/daily/999.local Tue May 30 16:09:54 2017 (r319221) @@ -20,7 +20,12 @@ do echo '' case "$script" in /*) - if [ -f "$script" ] + if [ -x "$script" ] + then + echo "Running $script:" + + $script || rc=3 + elif [ -f "$script" ] then echo "Running $script:" Modified: stable/10/etc/periodic/monthly/999.local ============================================================================== --- stable/10/etc/periodic/monthly/999.local Tue May 30 16:05:11 2017 (r319220) +++ stable/10/etc/periodic/monthly/999.local Tue May 30 16:09:54 2017 (r319221) @@ -17,7 +17,12 @@ do echo '' case "$script" in /*) - if [ -f "$script" ] + if [ -x "$script" ] + then + echo "Running $script:" + + $script || rc=3 + elif [ -f "$script" ] then echo "Running $script:" Modified: stable/10/etc/periodic/weekly/999.local ============================================================================== --- stable/10/etc/periodic/weekly/999.local Tue May 30 16:05:11 2017 (r319220) +++ stable/10/etc/periodic/weekly/999.local Tue May 30 16:09:54 2017 (r319221) @@ -17,7 +17,12 @@ do echo '' case "$script" in /*) - if [ -f "$script" ] + if [ -x "$script" ] + then + echo "Running $script:" + + $script || rc=3 + elif [ -f "$script" ] then echo "Running $script:"