Silence errors when directory to be checked does not exist (system may have been installed without a web interface!)

Signed-off-by: DL6ER <dl6er@dl6er.de>
pull/1752/head
DL6ER 7 years ago
parent 7362416afb
commit 0db76aada0
No known key found for this signature in database
GPG Key ID: 00135ACBD90B28DD

@ -37,7 +37,7 @@ function get_local_branch() {
directory="${1}"
local output
cd "${directory}" || return 1
cd "${directory}" 2> /dev/null || return 1
# Store STDERR as STDOUT variable
output=$( { git rev-parse --abbrev-ref HEAD; } 2>&1 )
echo "$output"
@ -59,7 +59,7 @@ function get_local_version() {
directory="${1}"
local output
cd "${directory}" || return 1
cd "${directory}" 2> /dev/null || return 1
# Store STDERR as STDOUT variable
output=$( { git describe --long --dirty --tags; } 2>&1 )
echo "$output"

Loading…
Cancel
Save