Oops, turns out I didn't save my test case correctly and the supplied
patch didn't fix it.

The attached patch fixes the issue correctly (to be applied to git
master), and the test case supplied actually works.

Cheers!

-- 
Andrew Ruthven
Wellington, New Zealand
At home: [email protected] |   linux.conf.au 2013
                           | Come join the party...
                           |  http://linux.conf.au
From deae9213321e964a3186c68bb7c004168b826c49 Mon Sep 17 00:00:00 2001
From: Andrew Ruthven <[email protected]>
Date: Wed, 9 May 2012 11:52:53 +1200
Subject: [PATCH] Remove the double quotes so the pattern expansion works.

---
 bin/fai-do-scripts |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/bin/fai-do-scripts b/bin/fai-do-scripts
index 7e6e1b5..2595f94 100755
--- a/bin/fai-do-scripts
+++ b/bin/fai-do-scripts
@@ -142,7 +142,7 @@ do_script() {
             fc_check_status $file $exitcode | tee -a $LOGDIR/cfengine.log
         ;;
 
-        *"[Pp]erl"*"script"*)
+        *[Pp]erl*script*)
             echo "Executing    perl: $file"
             echo "=====   perl: $file   =====" >> $LOGDIR/perl.log 2>&1
             ./$file >> $LOGDIR/perl.log 2>&1
@@ -158,7 +158,7 @@ do_script() {
             fc_check_status $file $exitcode | tee -a $LOGDIR/expect.log
         ;;
 
-        *"[Pp]ython"*"script"*)
+        *[Pp]ython*script*)
             echo "Executing  python: $file"
             echo "=====   python: $file   =====" >> $LOGDIR/python.log 2>&1
             ./$file >> $LOGDIR/python.log 2>&1
@@ -166,7 +166,7 @@ do_script() {
             fc_check_status $file $exitcode | tee -a $LOGDIR/python.log
         ;;
 
-        *"[Rr]uby"*"script"*)
+        *[Rr]uby*script*)
             echo "Executing ruby: $file"
             echo "=====   ruby: $file   =====" >> $LOGDIR/ruby.log 2>&1
             ./$file >> $LOGDIR/ruby.log 2>&1
-- 
1.7.10

Attachment: test-case.sh
Description: application/shellscript

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to