diff options
Diffstat (limited to 'xmake/templates/c/console/_template.lua')
| -rw-r--r-- | xmake/templates/c/console/_template.lua | 21 |
1 files changed, 1 insertions, 20 deletions
diff --git a/xmake/templates/c/console/_template.lua b/xmake/templates/c/console/_template.lua index a24baffee..e1475e286 100644 --- a/xmake/templates/c/console/_template.lua +++ b/xmake/templates/c/console/_template.lua @@ -31,31 +31,12 @@ local utils = require("base/utils") -- init the template description _template.description = "The Console Program" --- create project using this template +-- done the template file function _template.done(targetname, projectdir) -- check assert(targetname and projectdir) - -- check the template project - if not os.isdir("project") then - -- errors - utils.error("the template project not exists!") - return false - end - - -- ensure the project directory - if not os.isdir(projectdir) then - os.mkdir(projectdir) - end - - -- copy the project files - if not os.cp("project/*", projectdir) then - -- errors - utils.error("install project failed!") - return false - end - -- ok return true end |
