summaryrefslogtreecommitdiff
path: root/xmake
diff options
context:
space:
mode:
authorruki <[email protected]>2026-03-04 00:46:35 +0800
committerruki <[email protected]>2026-03-04 00:46:35 +0800
commit6697684c141ef8e80d1e1d9a89770167f2344cdd (patch)
tree1d67ca1fca096618be0accd5562f5df338e8dac3 /xmake
parent078b2ee0b6087a70bae05d3fa86d01078786513c (diff)
improve tip info
Diffstat (limited to 'xmake')
-rw-r--r--xmake/actions/create/main.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/xmake/actions/create/main.lua b/xmake/actions/create/main.lua
index 72b69f3b2..89a4791a6 100644
--- a/xmake/actions/create/main.lua
+++ b/xmake/actions/create/main.lua
@@ -194,7 +194,9 @@ function _create_project(lang, templateid, targetname)
-- create project
local sourcedir = template.templatedir(lang, templateid)
- assert(sourcedir, "template(%s/%s): not found!", lang, templateid)
+ if not sourcedir then
+ raise("template(%s/%s): not found!\nyou can try:\n - xrepo update-repo (update repositories)\n - xmake create --list (show available templates)", lang, templateid)
+ end
-- get the builtin variables
local builtinvars = template.builtinvars(targetname)