New File tools

This commit is contained in:
2023-02-08 20:05:41 -08:00
parent c3dbacde76
commit bbe30d9253
13 changed files with 210 additions and 73 deletions

View File

@@ -5,10 +5,27 @@
#include "DawnTool.hpp"
#if !defined(DAWN_TOOL_INSTANCE)
#error Dawn Tool Instance, e.g. LanguageTool has not been defined
#endif
#if !defined(DAWN_TOOL_HEADER)
#error Dawn Tool Include, e.g. LanguageTool.hpp has not been defined
#endif
#include DAWN_TOOL_HEADER
using namespace Dawn;
DawnTool::DawnTool(const int argc, const char *argv[]) {
int32_t DawnTool::exec(const int32_t argc, const char *argv[]) {
for(int32_t i = 0; i < argc; i++) {
this->args.push_back(std::string(argv[i]));
}
return this->start();
}
int main(const int32_t argc, const char *argv[]) {
DAWN_TOOL_INSTANCE self;
return self.exec(argc, argv);
}