Skip to content

Commit

Permalink
OFPGVersion back in XCode Project
Browse files Browse the repository at this point in the history
we now have back in project.pbxproj a way of knowing which version of projectGenerator was used to build.
useful to debug problems in projects from nightly builds
  • Loading branch information
dimitre authored Aug 29, 2024
1 parent 8c94b76 commit 4d35d91
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions commandLine/src/defines.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#define OFPROJECTGENERATOR_MAJOR_VERSION 0
#define OFPROJECTGENERATOR_MINOR_VERSION 72
#define OFPROJECTGENERATOR_MINOR_VERSION 73
#define OFPROJECTGENERATOR_PATCH_VERSION 0

#define PG_VERSION "0.72.0"
#define PG_VERSION "0.73.0"
8 changes: 4 additions & 4 deletions commandLine/src/projects/xcodeProject.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,8 @@ void xcodeProject::saveMakefile(){


bool xcodeProject::loadProjectFile(){ //base
addCommand("Add :_OFProjectGeneratorVersion string " + getPGVersion());

renameProject();
// MARK: just to return something.
return true;
Expand Down Expand Up @@ -902,11 +904,8 @@ bool xcodeProject::saveProjectFile(){

contents.close();


// j["_OFProjectGeneratorVersion"] = getPGVersion();


for (auto & c : commands) {
//alert (c, 31);
// readable comments enabled now.
if (c != "" && c[0] != '#') {
vector<string> cols { ofSplitString(c, " ") };
Expand Down Expand Up @@ -958,6 +957,7 @@ bool xcodeProject::saveProjectFile(){


std::ofstream jsonFile(fileName);
// This is not pretty but address some differences in nlohmann json 3.11.2 to 3.11.3
auto dump = j.dump(1, ' ');
if (dump[0] == '[') {
dump = j[0].dump(1, ' ');
Expand Down

0 comments on commit 4d35d91

Please sign in to comment.