From 6ec9962697b9db50740bba79ccae1cd9b58f4003 Mon Sep 17 00:00:00 2001 From: Matthijs Kooijman Date: Thu, 7 Dec 2017 10:34:47 +0100 Subject: [PATCH 1/2] Print "archiving core" message at INFO level This previously used the DEBUG level, which is shown in red by the Arduino IDE. Commit 7883e01 (Let "archiving core" message appear only if verbose) attempted to fix this, but did not. While here, this also changes Fprintln with an explicit Stdout argument to a regular Println, since Stdout is the default anyway. This commit properly fixes #238. Signed-off-by: Matthijs Kooijman --- src/arduino.cc/builder/phases/core_builder.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/arduino.cc/builder/phases/core_builder.go b/src/arduino.cc/builder/phases/core_builder.go index ff18231d..64352c5d 100644 --- a/src/arduino.cc/builder/phases/core_builder.go +++ b/src/arduino.cc/builder/phases/core_builder.go @@ -30,7 +30,6 @@ package phases import ( - "os" "path/filepath" "arduino.cc/builder/builder_utils" @@ -128,7 +127,7 @@ func compileCore(buildPath string, buildCachePath string, buildProperties proper // archive core.a if targetArchivedCore != "" { if verbose { - logger.Fprintln(os.Stdout, constants.LOG_LEVEL_DEBUG, constants.MSG_ARCHIVING_CORE_CACHE, targetArchivedCore) + logger.Println(constants.LOG_LEVEL_INFO, constants.MSG_ARCHIVING_CORE_CACHE, targetArchivedCore) } builder_utils.CopyFile(archiveFile, targetArchivedCore) } From 3dc280d39ed0364c6483d2eb9ce16eaf95aaee47 Mon Sep 17 00:00:00 2001 From: Matthijs Kooijman Date: Thu, 7 Dec 2017 10:39:10 +0100 Subject: [PATCH 2/2] Show filename in "using precompiled core" message This is more consistent with other similar messages (e.g. "Using previously compiled file") and provides a direct hint to the user where this cached core can be deleted if needed. Signed-off-by: Matthijs Kooijman --- src/arduino.cc/builder/phases/core_builder.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/arduino.cc/builder/phases/core_builder.go b/src/arduino.cc/builder/phases/core_builder.go index 64352c5d..92eef40a 100644 --- a/src/arduino.cc/builder/phases/core_builder.go +++ b/src/arduino.cc/builder/phases/core_builder.go @@ -108,7 +108,7 @@ func compileCore(buildPath string, buildCachePath string, buildProperties proper if canUseArchivedCore { // use archived core if verbose { - logger.Println(constants.LOG_LEVEL_INFO, "Using precompiled core") + logger.Println(constants.LOG_LEVEL_INFO, "Using precompiled core: {0}", targetArchivedCore) } return targetArchivedCore, variantObjectFiles, nil }