Skip to content

Commit

Permalink
Introduce a force update value for reloading cache #82
Browse files Browse the repository at this point in the history
  • Loading branch information
awalsh128 committed Feb 3, 2023
1 parent 9b3b2b5 commit 9ecdf39
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pre_cache_action.sh
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,11 @@ log "Creating cache key..."
normalized_versioned_packages="$(normalize_package_list "${versioned_packages}")"
log "- Normalized package list is '${normalized_versioned_packages}'."

value="${normalized_versioned_packages} @ ${version}"
# Forces an update in cases where an accidental breaking change was introduced
# and a global cache reset is required.
force_update_inc="0"

value="${normalized_versioned_packages} @ ${version} ${force_update_inc}"
log "- Value to hash is '${value}'."

key="$(echo "${value}" | md5sum | cut -f1 -d' ')"
Expand Down

0 comments on commit 9ecdf39

Please sign in to comment.