diff --git a/projects/.template/description.yaml b/projects/.template/description.yaml index 5f50e19f..49957382 100644 --- a/projects/.template/description.yaml +++ b/projects/.template/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: My Fancy dApp authors: @@ -18,7 +19,7 @@ codeUrl: https://github.com/johnsmith/my-fancy-dapp demoUrl: https://johnsmith.com/my-fancy-dapp tutorials: - Three Steps to build a Confidential Online Shop: - https://docs.oasis.io/dapp/sapphire/gasless + https://docs.oasis.io/dapp/sapphire/gasless created: 2023-08-15 lastUpdated: 2023-09-18 maintainedByOasis: false diff --git a/projects/.template/project.schema.json b/projects/.template/project.schema.json new file mode 100644 index 00000000..bce1ef17 --- /dev/null +++ b/projects/.template/project.schema.json @@ -0,0 +1,368 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "authors": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": { + "type": "string", + "format": "uri" + } + } + }, + "description": { + "type": "string" + }, + "paratimes": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "consensus", + "cipher", + "emerald", + "sapphire" + ] + } + }, + "languages": { + "type": "array", + "items": { + "type": "string", + "enum": [ + "none", + "plain", + "plaintext", + "text", + "txt", + "html", + "xml", + "svg", + "mathml", + "ssml", + "rss", + "css", + "clike", + "js", + "javascript", + "abap", + "abnf", + "al", + "antlr4", + "g4", + "apacheconf", + "apl", + "aql", + "ino", + "arff", + "armasm", + "arm-asm", + "art", + "asciidoc", + "adoc", + "aspnet", + "asm6502", + "asmatmel", + "autohotkey", + "autoit", + "avisynth", + "avs", + "avro-idl", + "avdl", + "awk", + "gawk", + "sh", + "basic", + "bbcode", + "bbj", + "bnf", + "rbnf", + "bqn", + "bsl", + "oscript", + "csharp", + "cs", + "dotnet", + "cpp", + "cfscript", + "cfc", + "cil", + "cilkc", + "cilk-c", + "cilkcpp", + "cilk-cpp", + "cilk", + "cmake", + "cobol", + "coffee", + "conc", + "csp", + "css-extras", + "csv", + "cue", + "dataweave", + "dax", + "django", + "jinja2", + "dns-zone-file", + "dns-zone", + "dockerfile", + "dot", + "gv", + "ebnf", + "editorconfig", + "ejs", + "etlua", + "erb", + "excel-formula", + "xlsx", + "xls", + "fsharp", + "firestore-security-rules", + "ftl", + "gml", + "gamemakerlanguage", + "gap", + "gcode", + "gdscript", + "gedcom", + "gettext", + "po", + "glsl", + "gn", + "gni", + "linker-script", + "ld", + "go-module", + "go-mod", + "graphql", + "hbs", + "hs", + "hcl", + "hlsl", + "http", + "hpkp", + "hsts", + "ichigojam", + "icu-message-format", + "idr", + "ignore", + "gitignore", + "hgignore", + "npmignore", + "inform7", + "javadoc", + "javadoclike", + "javastacktrace", + "jq", + "jsdoc", + "js-extras", + "json", + "webmanifest", + "json5", + "jsonp", + "jsstacktrace", + "js-templates", + "keepalived", + "kts", + "kt", + "kumir", + "kum", + "latex", + "tex", + "context", + "lilypond", + "ly", + "emacs", + "elisp", + "emacs-lisp", + "llvm", + "log", + "lolcode", + "magma", + "md", + "markup-templating", + "matlab", + "maxscript", + "mel", + "metafont", + "mongodb", + "moon", + "n1ql", + "n4js", + "n4jsd", + "nand2tetris-hdl", + "naniscript", + "nani", + "nasm", + "neon", + "nginx", + "nsis", + "objectivec", + "objc", + "ocaml", + "opencl", + "openqasm", + "qasm", + "parigp", + "objectpascal", + "psl", + "pcaxis", + "px", + "peoplecode", + "pcode", + "php", + "phpdoc", + "php-extras", + "plant-uml", + "plantuml", + "plsql", + "powerquery", + "pq", + "mscript", + "powershell", + "promql", + "properties", + "protobuf", + "purebasic", + "pbfasm", + "purs", + "py", + "qsharp", + "qs", + "q", + "qml", + "rkt", + "cshtml", + "razor", + "jsx", + "tsx", + "renpy", + "rpy", + "res", + "rest", + "robotframework", + "robot", + "rb", + "sas", + "sass", + "scss", + "shell-session", + "sh-session", + "shellsession", + "sml", + "smlnj", + "solidity", + "sol", + "solution-file", + "sln", + "soy", + "sparql", + "rq", + "splunk-spl", + "sqf", + "sql", + "stata", + "iecst", + "supercollider", + "sclang", + "systemd", + "t4-templating", + "t4-cs", + "t4", + "t4-vb", + "tap", + "tt2", + "toml", + "trickle", + "troy", + "trig", + "ts", + "typescript", + "tsconfig", + "uscript", + "uc", + "uorazor", + "uri", + "url", + "vbnet", + "vhdl", + "vim", + "visual-basic", + "vba", + "vb", + "wasm", + "web-idl", + "webidl", + "wgsl", + "wiki", + "wolfram", + "nb", + "wl", + "xeoracube", + "xml-doc", + "xojo", + "xquery", + "yaml", + "yml", + "yang" + ] + } + }, + "license": { + "type": "string" + }, + "tags": { + "type": "array", + "items": { + "type": "string" + } + }, + "codeUrl": { + "type": "string", + "format": "uri" + }, + "demoUrl": { + "type": "string", + "format": "uri" + }, + "tutorials": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": { + "type": "string", + "format": "uri" + } + } + }, + "created": { + "type": "string", + "format": "date" + }, + "lastUpdated": { + "type": "string", + "format": "date" + }, + "maintainedByOasis": { + "type": "boolean" + } + }, + "required": [ + "name", + "authors", + "description", + "paratimes", + "languages", + "license", + "tags", + "created", + "lastUpdated", + "maintainedByOasis" + ] +} diff --git a/projects/authzn/description.yaml b/projects/authzn/description.yaml index f8613b4a..4851aa40 100644 --- a/projects/authzn/description.yaml +++ b/projects/authzn/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Oasis Authenticator authors: diff --git a/projects/dapp-wrose/description.yaml b/projects/dapp-wrose/description.yaml index 648a8786..05ccb6bc 100644 --- a/projects/dapp-wrose/description.yaml +++ b/projects/dapp-wrose/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: ROSE (un) wrapper authors: diff --git a/projects/demo-authzn/description.yaml b/projects/demo-authzn/description.yaml index dd3b26d9..19616a2e 100644 --- a/projects/demo-authzn/description.yaml +++ b/projects/demo-authzn/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Authenticator Demo authors: diff --git a/projects/demo-e2eproxy/description.yaml b/projects/demo-e2eproxy/description.yaml index 82daf1d9..e41461d3 100644 --- a/projects/demo-e2eproxy/description.yaml +++ b/projects/demo-e2eproxy/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: E2E Proxy authors: diff --git a/projects/demo-oasisriddle/description.yaml b/projects/demo-oasisriddle/description.yaml index 2f91aa9c..8c579144 100644 --- a/projects/demo-oasisriddle/description.yaml +++ b/projects/demo-oasisriddle/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Oasis Riddle authors: diff --git a/projects/demo-oasisswag/description.yaml b/projects/demo-oasisswag/description.yaml index 918d4e59..d79831f1 100644 --- a/projects/demo-oasisswag/description.yaml +++ b/projects/demo-oasisswag/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Oasis Swag authors: diff --git a/projects/demo-opl-secret-ballot/description.yaml b/projects/demo-opl-secret-ballot/description.yaml index 4be08b45..a95314a7 100644 --- a/projects/demo-opl-secret-ballot/description.yaml +++ b/projects/demo-opl-secret-ballot/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: OPL Secret Ballot authors: diff --git a/projects/demo-starter/description.yaml b/projects/demo-starter/description.yaml index fcfdd5e3..f6b08844 100644 --- a/projects/demo-starter/description.yaml +++ b/projects/demo-starter/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Starter Project authors: diff --git a/projects/demo-voting/description.yaml b/projects/demo-voting/description.yaml index 2124ef22..2f1ae528 100644 --- a/projects/demo-voting/description.yaml +++ b/projects/demo-voting/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Confidential Voting authors: diff --git a/projects/example-cipher-c10l-hello-world/description.yaml b/projects/example-cipher-c10l-hello-world/description.yaml index 0abaa680..61b76498 100644 --- a/projects/example-cipher-c10l-hello-world/description.yaml +++ b/projects/example-cipher-c10l-hello-world/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Confidential Hello World on Cipher authors: diff --git a/projects/example-cipher-hello-world/description.yaml b/projects/example-cipher-hello-world/description.yaml index 883fe434..465ba547 100644 --- a/projects/example-cipher-hello-world/description.yaml +++ b/projects/example-cipher-hello-world/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Hello World on Cipher authors: diff --git a/projects/example-sapphire-hardhat/description.yaml b/projects/example-sapphire-hardhat/description.yaml index 333bfc4d..06e2b278 100644 --- a/projects/example-sapphire-hardhat/description.yaml +++ b/projects/example-sapphire-hardhat/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: Hardhat Sapphire Example authors: diff --git a/projects/example-sapphire-onchain-signer/description.yaml b/projects/example-sapphire-onchain-signer/description.yaml index 44d1034f..28b4f96d 100644 --- a/projects/example-sapphire-onchain-signer/description.yaml +++ b/projects/example-sapphire-onchain-signer/description.yaml @@ -1,3 +1,4 @@ +# yaml-language-server: $schema=../.template/project.schema.json --- name: On-Chain Signer authors: diff --git a/src/types.ts b/src/types.ts index e1407b03..0efadefa 100644 --- a/src/types.ts +++ b/src/types.ts @@ -8,7 +8,7 @@ export interface Project { license: string; tags: string[]; codeUrl?: string; - demoUrl: string; + demoUrl?: string; tutorials?: { [tutorial: string]: string }[]; created: string; lastUpdated: string;