You should mention your target OS in the question.
Linux: compute a single hash for a given folder & contents? could be a candidate for a duplicate, if you're looking for a Linux solution.