Generate a full project with PhoenixDataStream and PhoenixTypeStream.
296 std::cerr <<
"project_generator : cannot parse project description file '"<<descriptionFile<<
"'" << std::endl;
300 PPath mainProjectDir(projectConfig.
name);
301 if(!mainProjectDir.createDirectory()){
302 std::cerr <<
"project_generator : cannot create main directory of project '"<<mainProjectDir<<
"'" << std::endl;
306 PPath mainProjectSrc(mainProjectDir /
PPath(
"src"));
307 if(!mainProjectSrc.createDirectory()){
308 std::cerr <<
"project_generator : cannot create source directory of project '"<<mainProjectSrc<<
"'" << std::endl;
314 std::cerr <<
"project_generator : can't save file '"<<className<<
"'[.h or .cpp]" << std::endl;
318 PPath cmakeListsSrc(mainProjectSrc /
PPath(
"CMakeLists.txt"));
321 PPath cmakeListsMain(mainProjectDir /
PPath(
"CMakeLists.txt"));
324 PPath cmakeListsTest(mainProjectDir /
PPath(
"TESTS/CMakeLists.txt"));
327 PPath readmeFile(mainProjectDir /
PPath(
"README.md"));
330 PPath gitignoreFile(mainProjectDir /
PPath(
".gitignore"));
333 PPath gitlabciFile(mainProjectDir /
PPath(
".gitlab-ci.yml"));
Path of a directory or a file.
PPath & eraseExtension()
Erase the extension of the PPath.
PPath getFileName() const
Get the name of the file, from last char to /.
PString toLower() const
Convert PString in lower case.
bool saveParserClassConfig(const PPath &baseFileNameOutput, const PPath &fileName, bool enableDataStream, bool enableTypeStream, bool enableUnitTest, const PPath &testParentDir, const PString &libName)
Parser list class config.
bool project_generator_cmakeListsMain(const PPath &fileName, const ProjectConfig &projectConfig, const PString &baseConfigClassName)
Create the main CMakeLists.txt of the project directory.
bool project_generator_cmakeListsSrc(const PPath &fileName, const PString &projectName, const PString &libName)
Create the CMakeLists.txt of the src directory.
bool project_generator_gitlabci(const PPath &fileName, const ProjectConfig &projectConfig)
Create the .gitlab-ci.yml of the project.
bool project_generator_gitignore(const PPath &fileName)
Create the .gitignore of the project.
bool project_generator_readme(const PPath &fileName, const ProjectConfig &projectConfig)
Create the readme of the project directory.
bool project_generator_cmakeListsTest(const PPath &fileName, const PString &baseConfigClassName)
Create the main CMakeLists.txt of the project directory.
bool project_generator_loadConfig(ProjectConfig &config, const PPath &descriptionFile)
Load the project configuration.
Configuration of the project.
PString name
Name of the project.
bool project_wrapper_generator(const ProjectConfig &projectConfig, const PPath &configFile)
Generate a full python wrapper project with PhoenixDataStream and PhoenixTypeStream.