#!/bin/sh find "${1-.}" | LC_ALL=C sort | xargs cat | md5sum # Takes ~30% longer with sha256sum, and the output is longer (e.g., # "c386d9898dc1367c04ca82ee18a44377367e14ff5444cf1b1e9a08903a979865" # instead of "7a06aaaa35506ee61ed6fe97fd2ae9cf"), making it a little # bit harder to do a quick manual comparison. Yes, in some technical # sense md5sum is "broken" these days, but not in any way that matters # for this script -- and if it ever does, the Levenshtein Distance # from current script to revised script is pretty small :-).