From 676a4c1ee3204b5239de17c8df384ca49dbb1c21 Mon Sep 17 00:00:00 2001 From: Xavier BESSON Date: Thu, 15 Dec 2022 21:37:29 +0100 Subject: [PATCH] Fix CMakeFormatter CMakeFormatter was executed on the file on disk before save, which messed things completely up (PipeProcessing seems to expect the file on disk already to be saved) Change-Id: Idc7b475b5cddeaba4dc7bcc1b7899d73b2692310 Reviewed-by: Cristian Adam --- src/plugins/cmakeprojectmanager/cmakeformatter.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/plugins/cmakeprojectmanager/cmakeformatter.cpp b/src/plugins/cmakeprojectmanager/cmakeformatter.cpp index 061f7cc4fb0..6038f7967ce 100644 --- a/src/plugins/cmakeprojectmanager/cmakeformatter.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeformatter.cpp @@ -44,7 +44,8 @@ Command CMakeFormatter::command() const { Command command; command.setExecutable(CMakeFormatterSettings::instance()->command().toString()); - command.setProcessing(Command::PipeProcessing); + command.setProcessing(Command::FileProcessing); + command.addOption("--in-place"); command.addOption("%file"); return command; }