Excellent script Jason.
But I can see one area where just synchronizing logins + users using the script may fall short.
Groups + users + aliases that existed in the target database but were missing from source database have to be recreated. So you have to provide some logic for this.
Solution I suggested (using ddlgen + queries ) takes care of that.
Avinash