From 8c5bfdb7777d7f670eac107bca15143836ca833d Mon Sep 17 00:00:00 2001 From: Amlal El Mahrouss Date: Fri, 13 Feb 2026 11:46:49 +0100 Subject: feat: build: fix build system log. Signed-off-by: Amlal El Mahrouss --- include/NeBuildKit/Detail/Config.h | 7 +++---- src/lib/JSONManifestBuilder.cc | 8 ++++---- src/lib/TOMLManifestBuilder.cc | 4 ++-- 3 files changed, 9 insertions(+), 10 deletions(-) diff --git a/include/NeBuildKit/Detail/Config.h b/include/NeBuildKit/Detail/Config.h index 7bc25fc..e292fbe 100644 --- a/include/NeBuildKit/Detail/Config.h +++ b/include/NeBuildKit/Detail/Config.h @@ -34,10 +34,9 @@ namespace NeBuild { struct BuildConfig final { - b_internal: - bool has_failed_{false}; - bool dry_run_{false}; - std::string path_{}; + b_internal : bool has_failed_{false}; + bool dry_run_{false}; + std::string path_{}; public: explicit operator bool() { return has_failed_; } diff --git a/src/lib/JSONManifestBuilder.cc b/src/lib/JSONManifestBuilder.cc index 01b7de2..5d18612 100644 --- a/src/lib/JSONManifestBuilder.cc +++ b/src/lib/JSONManifestBuilder.cc @@ -21,13 +21,13 @@ bool JSONManifestBuilder::BuildTarget(BuildConfig& config) { std::string path; if (config.path_.empty()) { - NeBuild::Logger::info() << "nebuild: error: file path is empty" << std::endl; + NeBuild::Logger::info() << "error: file path is empty" << std::endl; return false; } else { path = config.path_; if (!FS::exists(path)) { - NeBuild::Logger::info() << "nebuild: error: file '" << path << "' does not exist" + NeBuild::Logger::info() << "error: file '" << path << "' does not exist" << std::endl; return false; } @@ -37,7 +37,7 @@ bool JSONManifestBuilder::BuildTarget(BuildConfig& config) { std::ifstream json(path); if (!json.good()) { - NeBuild::Logger::info() << "nebuild: error: file '" << path + NeBuild::Logger::info() << "error: file '" << path << "' is not a valid nlohmann::json" << std::endl; return false; } @@ -47,7 +47,7 @@ bool JSONManifestBuilder::BuildTarget(BuildConfig& config) { try { nlohmann::json description = json_obj["description"]; - NeBuild::Logger::info() << "nebuild: installing: " << path << std::endl; + NeBuild::Logger::info() << "package path: " << path << std::endl; if (auto res = description.get(); !res.empty()) NeBuild::Logger::info() << "nebuild: description: " << res << std::endl; diff --git a/src/lib/TOMLManifestBuilder.cc b/src/lib/TOMLManifestBuilder.cc index c28b6bd..5b265dd 100644 --- a/src/lib/TOMLManifestBuilder.cc +++ b/src/lib/TOMLManifestBuilder.cc @@ -21,13 +21,13 @@ bool TOMLManifestBuilder::BuildTarget(BuildConfig& config) { std::string path; if (config.path_.empty()) { - NeBuild::Logger::info() << "nebuild: error: file path is empty" << std::endl; + NeBuild::Logger::info() << "error: file path is empty" << std::endl; return false; } else { path = config.path_; if (!FS::exists(path)) { - NeBuild::Logger::info() << "nebuild: error: file '" << path << "' does not exist" + NeBuild::Logger::info() << "error: file '" << path << "' does not exist" << std::endl; return false; } -- cgit v1.2.3