diff --git a/borgbackup.sh b/borgbackup.sh index 9fff3c3..fa6b8bf 100755 --- a/borgbackup.sh +++ b/borgbackup.sh @@ -49,12 +49,14 @@ if test -f /etc/borgbackup.conf; then source /etc/borgbackup.conf fi -# Define the expect script in a variable -expect_script=$(cat < "$expect_script_file" - -# Make the temporary expect script executable -chmod +x "$expect_script_file" - -# Execute the expect script -$expect_script_file - -# Clean up the temporary expect script -rm -f "$expect_script_file" +echo "Borg exit status: exit_status=$?" echo "Running POSTHOOK..." -eval $POSTHOOK \ No newline at end of file +eval $POSTHOOK + +exit $exit_status \ No newline at end of file