Added handling of success and failed build.