Difference between revisions of "Bash-nexj"
(Created page with ' <big><big> Continuous Integration Project - Bash</big></big> {{NexJ_Express Index}} ==Bash Scripting Resources== :[http://www.faqs.org/docs/Linux-HOWTO/Bash-Prog-Intro-HOWTO.ht…') |
|||
Line 1: | Line 1: | ||
+ | [[Category:NexJ_Express_Continuous_Integration]] | ||
+ | <big><big> Continuous Integration Project - Bash</big></big> | ||
− | |||
− | |||
==Bash Scripting Resources== | ==Bash Scripting Resources== | ||
:[http://www.faqs.org/docs/Linux-HOWTO/Bash-Prog-Intro-HOWTO.html Tutorial] | :[http://www.faqs.org/docs/Linux-HOWTO/Bash-Prog-Intro-HOWTO.html Tutorial] |
Latest revision as of 15:37, 22 January 2011
Continuous Integration Project - Bash
Bash Scripting Resources
Tips
- Watch the spaces
if [ -d "$tmpInternal" ]; then
rm -r $tmpInternal >> $dateError.txt
elif [ -d "$tmpExternal" ]; then
rm -r $tmExternal >> $dateError.txt
fi
- The increment operator in bash
while [ $revTmpInternal -lt $revInternal ]; do
((revTmpInternal++))
done
- to check if a file exists:
if [ -f m.patch ]; then
rm *.patch
fi
- To check if multiple files exist:http://www.ducea.com/2009/03/05/bash-tips-if-e-wildcard-file-check-too-many-arguments/
errors=$(ls Error*.txt 2> /dev/null | wc -l)
if [ "$errors" != "0" ]; then
rm Error*.txt
fi
- Also this solution @ http://kenfallon.com/?p=4