Browse Source

make variables local

master
belliash 8 years ago
parent
commit
fa525ebe3e
1 changed files with 5 additions and 5 deletions
  1. +5
    -5
      libraries/filesystem

+ 5
- 5
libraries/filesystem View File

@@ -8,8 +8,8 @@
# Parameters: %directory%
#-------------------------------------------------------------------------------
function makeDirectory() {
OUTPUT=$(install -d "${@}" 2>&1)
RESULT=${?}
local OUTPUT=$(install -d "${@}" 2>&1)
local RESULT=${?}
if [[ ${RESULT} -ne 0 ]]; then
logOutput "${OUTPUT}"
fi
@@ -21,10 +21,10 @@ function makeDirectory() {
# Parameters: %source% %target%
#-------------------------------------------------------------------------------
function makeLink() {
DESTDIR="${2%/*}"
local DESTDIR="${2%/*}"
[[ ! -d ${DESTDIR} ]] && makeDirectory "${DESTDIR}"
OUTPUT=$(ln -sfn "${1}" "${2}" 2>&1)
RESULT=${?}
local OUTPUT=$(ln -sfn "${1}" "${2}" 2>&1)
local RESULT=${?}
if [[ ${RESULT} -ne 0 ]]; then
logOutput "${OUTPUT}"
fi


Loading…
Cancel
Save