From 262a851045fcb3c02366331190bea55ec36431c9 Mon Sep 17 00:00:00 2001 From: Gerhard Hoffmann Date: Thu, 2 Jun 2022 21:53:33 +0200 Subject: [PATCH] json/ini extended to json/ini/hex --- update_psa_impl | 21 +++++---------------- 1 file changed, 5 insertions(+), 16 deletions(-) diff --git a/update_psa_impl b/update_psa_impl index 9d7a859..7056f5d 100755 --- a/update_psa_impl +++ b/update_psa_impl @@ -86,20 +86,20 @@ update_psa() { # dateinen zu ueberpruefen local changed_files=$(changed_file_names) - local json_ini_files=$(filter_json_ini_files "$changed_files") + local files_to_copy=$(filter_changed_files "$changed_files" 'json|ini|hex') update_psa_report_changed_file_names $changed_files # message to ISMAS # check if *.conf and/or *.ini-files have to md5-sum as denoted # in update.conf - if ! check_md5_for_changed_json_and_ini_files "$json_ini_files" ; then + if ! check_md5_for_changed_json_and_ini_files "$files_to_copy" ; then local __r=$? log_error "$func:${LINENO}: new customer files wrong" revert_customer_repository exit $__r fi - if ! check_hardware_compatibility "$json_ini_files" ; then + if ! check_hardware_compatibility "$files_to_copy" ; then local __r=$? log_error "$func:${LINENO}: json/ini-files not fit for PSA" revert_customer_repository @@ -107,7 +107,7 @@ update_psa() { fi # copy *.conf and/or *.ini-files to their corresponding system-directories - if ! copy $json_ini_files; then + if ! copy $files_to_copy; then local __r=$? log_error "$func:${LINENO}: copy operation failed" revert_customer_repository @@ -167,20 +167,9 @@ update_psa() { log_error "$func:${LINENO}: cleanup_previous_version failed" fi - # TODO: nach (erfolgreichem) abschluss sollte man immer das aktuelle setting - # ans ISMAS schicken. ISMAS sollte immer wissen, was gerade auf dem - # Automaten steht. - update_psa_cleanup $UPDATE_ISMAS_PROGRESS \ $RC_SUCCESS "cleanup after psa update" - - update_psa_update_succeeded $UPDATE_SUCCEEDED \ - $RC_SUCCESS "psa update succeeded" - - update_psa_update_succeeded $UPDATE_ACTIVATED \ - $RC_SUCCESS "psa update activated" - - log_info "$func:${LINENO}: success" + exit 0 }