2022-10-03 06:45:10 +00:00
|
|
|
#include "CommandLineArgs.h"
|
|
|
|
|
2022-10-03 07:46:41 +00:00
|
|
|
#include "WebsiteGenerator.h"
|
2022-10-03 06:45:10 +00:00
|
|
|
|
|
|
|
int main(int argc, char *argv[])
|
|
|
|
{
|
|
|
|
auto args = CommandLineArgs::Create();
|
|
|
|
args->process(argc, argv);
|
|
|
|
args->recordLaunchPath();
|
|
|
|
|
|
|
|
WebsiteGenerator generator;
|
2023-01-13 14:29:12 +00:00
|
|
|
generator.findProject(args->getArgs()[1]);
|
2022-10-03 06:45:10 +00:00
|
|
|
|
|
|
|
generator.readConfig();
|
|
|
|
|
|
|
|
// Find and process project files
|
|
|
|
generator.parseContentFiles();
|
|
|
|
|
|
|
|
// Find template files
|
2022-10-11 19:20:12 +00:00
|
|
|
generator.parseTemplateFiles();
|
2022-10-03 06:45:10 +00:00
|
|
|
|
|
|
|
// Substitute template files
|
2022-12-05 13:16:10 +00:00
|
|
|
generator.doSubstitutions();
|
2022-10-03 06:45:10 +00:00
|
|
|
|
2022-10-04 07:20:39 +00:00
|
|
|
// Write output
|
|
|
|
generator.write();
|
2022-10-03 06:45:10 +00:00
|
|
|
|
|
|
|
return 0;
|
|
|
|
}
|