How to version serverless deployments and keep track? (aws)

I can’t find a resource on how to version each deployment and keep track of them.

I am aware that it is incrementing lambda version when functions are being deployed.

provider:
  versionFunctions: true

But, there is no easy way to know what code was deployed. I would want to be able to track which commit was deployed to each stage.