From 67d64be858eea21239a16eb3b2832532611f91a6 Mon Sep 17 00:00:00 2001 From: Mike Nolan Date: Tue, 23 Dec 2025 17:31:10 -0600 Subject: [PATCH] Add schema to templates and when project is generated --- Templates/compiletool/cross.json | 3 ++- Templates/console/cross.json | 3 ++- Templates/emptyweb/cross.json | 3 ++- Templates/lib/cross.json | 3 ++- Templates/template/cross.json | 3 ++- Templates/tool/cross.json | 3 ++- Templates/web/cross.json | 3 ++- Templates/webapp/cross.json | 3 ++- Tesses.CrossLang.Shell/src/new.tcross | 2 +- 9 files changed, 17 insertions(+), 9 deletions(-) diff --git a/Templates/compiletool/cross.json b/Templates/compiletool/cross.json index a27cae5..1ea1fff 100644 --- a/Templates/compiletool/cross.json +++ b/Templates/compiletool/cross.json @@ -14,5 +14,6 @@ "short_name_pretty": "Compile Tool", "template_ignored_files": ["bin","obj"], "description": "A tool that can be a dependency to a project (including libraries) that runs at compile time" - } + }, + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } diff --git a/Templates/console/cross.json b/Templates/console/cross.json index 416cba6..d13073d 100644 --- a/Templates/console/cross.json +++ b/Templates/console/cross.json @@ -17,5 +17,6 @@ "short_name_pretty": "Console Application", "template_ignored_files": ["bin","obj"], "description": "A console application" - } + }, + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } diff --git a/Templates/emptyweb/cross.json b/Templates/emptyweb/cross.json index 500e6a3..8bde1b2 100644 --- a/Templates/emptyweb/cross.json +++ b/Templates/emptyweb/cross.json @@ -15,5 +15,6 @@ "short_name_pretty": "Empty Website", "template_extra_text_ftles": [], "template_ignored_files": ["bin","obj"] - } + }, + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } diff --git a/Templates/lib/cross.json b/Templates/lib/cross.json index 6b9ddcc..436e366 100644 --- a/Templates/lib/cross.json +++ b/Templates/lib/cross.json @@ -14,5 +14,6 @@ "template_ignored_files": ["bin","obj"], "description": "A crosslang library", "short_name_pretty": "Library" - } + }, + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } diff --git a/Templates/template/cross.json b/Templates/template/cross.json index 0fc9da7..55f94d9 100644 --- a/Templates/template/cross.json +++ b/Templates/template/cross.json @@ -24,5 +24,6 @@ "template_extra_text_ftles": [], "template_ignored_files": ["bin","obj"], "short_name_pretty": "Template" - } + }, + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } diff --git a/Templates/tool/cross.json b/Templates/tool/cross.json index 89585f1..a492ecd 100644 --- a/Templates/tool/cross.json +++ b/Templates/tool/cross.json @@ -23,5 +23,6 @@ "short_name_pretty": "Tool" }, "version": "1.0.0.0-prod", - "name": "Tesses.CrossLang.Template.Tool" + "name": "Tesses.CrossLang.Template.Tool", + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } \ No newline at end of file diff --git a/Templates/web/cross.json b/Templates/web/cross.json index cf282d3..8265a0a 100644 --- a/Templates/web/cross.json +++ b/Templates/web/cross.json @@ -14,5 +14,6 @@ }, "template_ignored_files": ["bin","obj"], "short_name_pretty": "WebSite" - } + }, + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } diff --git a/Templates/webapp/cross.json b/Templates/webapp/cross.json index 7693c2a..1c6cb14 100644 --- a/Templates/webapp/cross.json +++ b/Templates/webapp/cross.json @@ -21,5 +21,6 @@ "description": "A web app (for webview or eventual cloud OS)" }, "name": "Tesses.CrossLang.Template.WebApp", - "version": "1.0.0.0-prod" + "version": "1.0.0.0-prod", + "$schema": "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json" } \ No newline at end of file diff --git a/Tesses.CrossLang.Shell/src/new.tcross b/Tesses.CrossLang.Shell/src/new.tcross index 18f27ce..2cf82b5 100644 --- a/Tesses.CrossLang.Shell/src/new.tcross +++ b/Tesses.CrossLang.Shell/src/new.tcross @@ -68,7 +68,7 @@ func Tesses.CrossLang.Shell.New(dd) var jsonText = FS.ReadAllText(projectDir, "/cross.json"); var proj = Json.Decode(jsonText); - + proj.["$schema"] = "https://crosslang.tesseslanguage.com//schema/cross-json-schema.json"; proj.name = projectPath.GetFileName(); proj.version = "1.0.0.0-prod"; var old_info = proj.info;