diff --git a/bin/compose-core b/bin/compose-core index 952d91f..0cb41b5 100755 --- a/bin/compose-core +++ b/bin/compose-core @@ -2241,12 +2241,18 @@ clean_unused_docker_compose() { export -f clean_unused_docker_compose -file_get_hash() { - local file="$1" sha - sha=$(sha256sum "$file") +stdin_get_hash() { + local sha + sha=$(sha256sum) || return 1 sha=${sha:0:64} echo "$sha" } +export -f stdin_get_hash + + +file_get_hash() { + stdin_get_hash < "$1" || return 1 +} export -f file_get_hash