Code formatting with no functional changes
This commit is contained in:
parent
2ce1280cc0
commit
a53f201842
@ -42,11 +42,14 @@ set -o nounset # Treat unset variables as an error
|
||||
# RETURNS: The path to the working directory
|
||||
#-------------------------------------------------------------------------------
|
||||
function make_working_dir {
|
||||
|
||||
# the directory of the script
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
# the temp directory used, within $DIR
|
||||
# omit the -p parameter to create a temporal directory in the default location
|
||||
# omit the -p parameter to create a temporal directory in
|
||||
# the default location
|
||||
|
||||
WORK_DIR=`mktemp -d -p "$DIR"`
|
||||
|
||||
# check if tmp dir was created
|
||||
@ -64,6 +67,7 @@ function make_working_dir {
|
||||
# RETURNS:
|
||||
#-------------------------------------------------------------------------------
|
||||
function clean_working_dir {
|
||||
|
||||
if [[ -d $1 ]] && expr $1 : '.*/tmp.*' ; then
|
||||
rm -rf $1
|
||||
echo "Deleted temp working directory $1"
|
||||
|
Reference in New Issue
Block a user