From 9bbb0182cde296009ccbac6f7f10a82e4c6f96ac Mon Sep 17 00:00:00 2001 From: Dimitre Date: Mon, 10 Jun 2024 11:37:38 -0300 Subject: [PATCH] v47 - _OFProjectGeneratorVersion --- commandLine/src/projects/baseProject.h | 2 +- commandLine/src/projects/xcodeProject.cpp | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/commandLine/src/projects/baseProject.h b/commandLine/src/projects/baseProject.h index 97630e25..2e276194 100644 --- a/commandLine/src/projects/baseProject.h +++ b/commandLine/src/projects/baseProject.h @@ -1,6 +1,6 @@ #pragma once -#define PG_VERSION "46" +#define PG_VERSION "47" #include "ofAddon.h" #include "pugixml.hpp" diff --git a/commandLine/src/projects/xcodeProject.cpp b/commandLine/src/projects/xcodeProject.cpp index 2ec0616f..45012055 100644 --- a/commandLine/src/projects/xcodeProject.cpp +++ b/commandLine/src/projects/xcodeProject.cpp @@ -799,8 +799,8 @@ bool xcodeProject::saveProjectFile(){ // debugCommands = true; - addCommand("# ---- PG VERSION " + getPGVersion()); - addCommand("Add :a_OFProjectGeneratorVersion string " + getPGVersion()); +// addCommand("# ---- PG VERSION " + getPGVersion()); +// addCommand("Add :a_OFProjectGeneratorVersion string " + getPGVersion()); fileProperties fp; // fp.isGroupWithoutFolder = true; @@ -838,6 +838,9 @@ bool xcodeProject::saveProjectFile(){ json j { json::parse(contents) }; contents.close(); + j["_OFProjectGeneratorVersion"] = getPGVersion(); + + for (auto & c : commands) { // readable comments enabled now. if (c != "" && c[0] != '#') { @@ -881,6 +884,7 @@ bool xcodeProject::saveProjectFile(){ } } + std::ofstream jsonFile(fileName); try { jsonFile << j.dump(1, ' ');