Skip to content

Commit

Permalink
Address lint-shell warnings.
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidHuber-NOAA committed Oct 24, 2023
1 parent 6b93dbc commit ee54dbc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions scripts/exgdas_enkf_earc.sh
Original file line number Diff line number Diff line change
Expand Up @@ -134,12 +134,12 @@ if [ "${ENSGRP}" -eq 0 ]; then
stat_chgrp=$?
${HSICMD} chmod 640 "${tar_fl}"
stat_chgrp=$((stat_chgrp+$?))
if [ "${stat_chgrp}" -gt 0 ]; then
if [[ "${stat_chgrp}" -gt 0 ]]; then
echo "FATAL ERROR: Unable to properly restrict ${tar_fl}!"
echo "Attempting to delete ${tar_fl}"
${HSICMD} rm "${tar_fl}"
echo "Please verify that ${tar_fl} was deleted!"
exit ${stat_chgrp}
exit "${stat_chgrp}"
fi
fi

Expand Down
6 changes: 3 additions & 3 deletions scripts/exglobal_archive.sh
Original file line number Diff line number Diff line change
Expand Up @@ -292,16 +292,16 @@ if [[ ${HPSSARCH} = "YES" || ${LOCALARCH} = "YES" ]]; then
echo "Attempting to delete ${tar_fl}"
${HSICMD} rm "${tar_fl}"
echo "Please verify that ${tar_fl} was deleted!"
exit ${stat_chgrp}
exit "${stat_chgrp}"
fi
fi
;;
*) ;;
esac

# For safety, test if the htar/tar command failed after changing groups
if [ "${status}" -ne 0 ] && [ "${PDY}${cyc}" -ge "${firstday}" ]; then
echo "FATAL ERROR: ${TARCMD} ${PDY}${cyc} ${targrp}.tar failed"
if [[ "${status}" -ne 0 ]] && [[ "${PDY}${cyc}" -ge "${firstday}" ]]; then
echo "FATAL ERROR: ${TARCMD} ${tar_fl} failed"
exit "${status}"
fi
set_strict
Expand Down

0 comments on commit ee54dbc

Please sign in to comment.