I don't think you should invest your time in this.
Deploying to S3 is controversial, involves personal preferences, there are already many tools[1] that say they do the same job as yours, each one is slightly different than the others.
There are also so many quirks difficult to solve from a script or command line tool, and at the same time so easy to solve using human inteligence at the time they happen.
[1]: Example: https://stout.is/