deploy: revamp conditions handling

This is a refactoring of the conditions handling that handles empty conditions (as in, no conditions are set at all) better. Before 40a5bdbee2ce63faf73d909070a1b8d77731df6d there was always at least one condition, the pull request condition, but this was pulled out to a Ruby condition, which caused the script to have `if [[ ]]` if no other conditions were set, causing a syntax error in the script.

Also contains some other Deploy addon refactorings that I noticed while working on this.