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
MFC after:	3 weeks
Sponsored by:	Spectra Logic Corp
This commit is contained in:
Alan Somers 2017-02-01 23:22:54 +00:00
parent 878097c10e
commit cb23468e75
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=313069
3 changed files with 18 additions and 3 deletions

View File

@ -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:"

View File

@ -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:"

View File

@ -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:"