Joachim Van Herwegen c216efd62f
feat: Allow for custom CLI and variable options
* feat: (AppRunner) Mechanism to configure cli args and derive componentsjs vars from them implemented

* fix: (AppRunner) tidying

* fix: (AppRunner) tidying up

* fix: (AppRunner) runCli method made sync

* fix; (VarResolver) refactored to multiple files, and other stylistic fixes.

* chore: (AppRunner) Uses builder pattern for yargs base arguments setup to enable better typescript inference

* fix(AppRunner): refactoring AppRunner and VarResolver

* fix(AppRunner): refactoring AppRunner promise handling

* fix(AppRunner): verror dependency removal

* fix: Simplify CLI error handling

* feat: Use same config for both CLI and app instantiation

* fix: Update typings and imports

* feat: Split VariableResolver behaviour to 2 classes

* feat: Move default value behaviour from CLI to ValueComputers

* test: Add unit tests for new CLI classes

* feat: Integrate new CLI configuration with all default configurations

* feat: Add createApp function to AppRunner

* docs: Update comments in CLI-related classes

* fix: Various fixes and refactors

Co-authored-by: damooo <damodara@protonmail.com>
2022-02-11 10:00:12 +01:00

68 lines
2.3 KiB
JSON

{
"@context": "https://linkedsoftwaredependencies.org/bundles/npm/@solid/community-server/^2.0.0/components/context.jsonld",
"@graph": [
{
"comment": "Extracts CLI arguments into a key/value object. Config and mainModulePath are only defined here so their description is returned.",
"@id": "urn:solid-server-app-setup:default:CliExtractor",
"@type": "YargsCliExtractor",
"parameters": {
"config": {
"alias": "c",
"requiresArg": true,
"type": "string",
"describe": "The configuration for the server. The default only stores data in memory; to persist to your filesystem, use @css:config/file.json."
},
"mainModulePath": {
"alias": "m",
"requiresArg": true,
"type": "string",
"describe": "Path from where Components.js will start its lookup when initializing configurations."
},
"loggingLevel": {
"alias": "l",
"requiresArg": true,
"type": "string",
"describe": "The detail level of logging; useful for debugging problems."
},
"baseUrl": {
"alias": "b",
"requiresArg": true,
"type": "string",
"describe": "The public URL of your server."
},
"port": {
"alias": "p",
"requiresArg": true,
"type": "number",
"describe": "The TCP port on which the server runs."
},
"rootFilePath": {
"alias": "f",
"requiresArg": true,
"type": "string",
"describe": "Root folder of the server, when using a file-based configuration."
},
"showStackTrace": {
"alias": "t",
"type": "boolean",
"describe": "Enables detailed logging on error pages."
},
"sparqlEndpoint": {
"alias": "s",
"requiresArg": true,
"type": "string",
"describe": "URL of the SPARQL endpoint, when using a quadstore-based configuration."
},
"podConfigJson": {
"requiresArg": true,
"type": "string",
"describe": "Path to the file that keeps track of dynamic Pod configurations."
}
},
"options": {
"usage": "node ./bin/server.js [args]"
}
}
]
}