This is done in [postgres-migrations](https://github.com/thomwright/postgres-migrations?tab=readme-ov-file#hash-checks-for-previous-migrations) and seems to be a good idea.