Prevent OSX From Opening Photos or Image Capture Automatically

Came across this OSX tip recently which will prevent Photos or Image Capture:

defaults -currentHost write com.apple.ImageCapture disableHotPlug -bool YES