From 687c59d3a44e0b9e1b3f19cbc9b1940da00b44df Mon Sep 17 00:00:00 2001 From: Takuto Ikuta Date: Tue, 29 Jan 2019 22:59:36 +0000 Subject: [PATCH] [autoninja] upload ninjalog even in failed build I noticed current autoninja does not upload build log in failed build. Change-Id: Ie58646b483e130769ad22113953c0b95b3145548 Reviewed-on: https://chromium-review.googlesource.com/c/1441892 Reviewed-by: Dirk Pranke Commit-Queue: Takuto Ikuta --- autoninja | 4 ++++ autoninja.bat | 3 +++ 2 files changed, 7 insertions(+) diff --git a/autoninja b/autoninja index 3847c3dc3..bac7c3e61 100755 --- a/autoninja +++ b/autoninja @@ -21,6 +21,10 @@ if eval "$command"; then "$(dirname -- "$0")/ninjalog_uploader_wrapper.py" --cmd $command exit fi + +# Collect ninjalog from googler. +"$(dirname -- "$0")/ninjalog_uploader_wrapper.py" --cmd $command + # Return an error code of 1 so that if a developer types: # "autoninja chrome && chrome" then chrome won't run if the build fails. exit 1 diff --git a/autoninja.bat b/autoninja.bat index ff8e4bd18..f8b05eff5 100755 --- a/autoninja.bat +++ b/autoninja.bat @@ -17,6 +17,9 @@ REM Use call to invoke python script here, because we use python via python.bat. exit /b :buildfailure + +@call python.bat %~dp0ninjalog_uploader_wrapper.py --cmdline %* + REM Return an error code of 1 so that if a developer types: REM "autoninja chrome && chrome" then chrome won't run if the build fails. cmd /c exit 1