diff --git a/norg.nimble b/norg.nimble index 4288661..f30058a 100644 --- a/norg.nimble +++ b/norg.nimble @@ -1,6 +1,6 @@ # Package -version = "0.1.12" +version = "0.1.13" author = "Paul Wilde" description = "A Borg Backup Orchestration Tool" license = "AGPL-3.0-or-later" diff --git a/norg/utils/run.nim b/norg/utils/run.nim index 974e210..307a754 100644 --- a/norg/utils/run.nim +++ b/norg/utils/run.nim @@ -5,9 +5,10 @@ import ../model/log_type proc run*(cmd: string): int = debug fmt"Trying to run : {cmd}" try: - let res = execCmd(cmd) - debug("Run Command Exist Code: " & $res) - return res + let (output,exitcode) = execCmdEx(cmd) + debug("Run Command Exist Code: " & $exitcode) + info(output) + return exitcode except: error getCurrentExceptionMsg() return 1 @@ -15,9 +16,10 @@ proc run*(cmd: string): int = proc runDiscard*(cmd: string): int = debug fmt"Trying to run : {cmd}" try: - let res = execCmd(cmd) - debug("Run Command Exist Code: " & $res) - return res + let (output,exitcode) = execCmdEx(cmd) + debug("Run Command Exist Code: " & $exitcode) + info(output) + return exitcode except: error getCurrentExceptionMsg() return 1