mirror of
https://github.com/spacedriveapp/spacedrive.git
synced 2025-12-11 20:15:30 +01:00
Add name and cmd to ShellScopeEntryAllowedArg
This commit is contained in:
parent
62564471dc
commit
f268acf57a
6
Cargo.lock
generated
6
Cargo.lock
generated
@ -10431,7 +10431,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "sd-cli"
|
name = "sd-cli"
|
||||||
version = "0.1.0"
|
version = "2.0.0-pre.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"bincode",
|
"bincode",
|
||||||
@ -10466,7 +10466,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "sd-core"
|
name = "sd-core"
|
||||||
version = "0.1.0"
|
version = "2.0.0-pre.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"aes-gcm",
|
"aes-gcm",
|
||||||
"anyhow",
|
"anyhow",
|
||||||
@ -10649,7 +10649,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "sd-server"
|
name = "sd-server"
|
||||||
version = "0.1.0"
|
version = "2.0.0-pre.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"axum",
|
"axum",
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -2023,6 +2023,14 @@
|
|||||||
"name"
|
"name"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"cmd": {
|
||||||
|
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2030,14 +2038,6 @@
|
|||||||
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
|
||||||
"cmd": {
|
|
||||||
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"additionalProperties": false
|
"additionalProperties": false
|
||||||
@ -2049,6 +2049,10 @@
|
|||||||
"sidecar"
|
"sidecar"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2057,10 +2061,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"sidecar": {
|
"sidecar": {
|
||||||
"description": "If this command is a sidecar command.",
|
"description": "If this command is a sidecar command.",
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
@ -2083,6 +2083,14 @@
|
|||||||
"name"
|
"name"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"cmd": {
|
||||||
|
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2090,14 +2098,6 @@
|
|||||||
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
|
||||||
"cmd": {
|
|
||||||
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"additionalProperties": false
|
"additionalProperties": false
|
||||||
@ -2109,6 +2109,10 @@
|
|||||||
"sidecar"
|
"sidecar"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2117,10 +2121,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"sidecar": {
|
"sidecar": {
|
||||||
"description": "If this command is a sidecar command.",
|
"description": "If this command is a sidecar command.",
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
@ -6290,34 +6290,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"ShellScopeEntryAllowedArg": {
|
|
||||||
"description": "A command argument allowed to be executed by the webview API.",
|
|
||||||
"anyOf": [
|
|
||||||
{
|
|
||||||
"description": "A non-configurable argument that is passed to the command in the order it was specified.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "A variable that is set while calling the command from the webview API.",
|
|
||||||
"type": "object",
|
|
||||||
"required": [
|
|
||||||
"validator"
|
|
||||||
],
|
|
||||||
"properties": {
|
|
||||||
"raw": {
|
|
||||||
"description": "Marks the validator as a raw regex, meaning the plugin should not make any modification at runtime.\n\nThis means the regex will not match on the entire string by default, which might be exploited if your regex allow unexpected input to be considered valid. When using this option, make sure your regex is correct.",
|
|
||||||
"default": false,
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
"validator": {
|
|
||||||
"description": "[regex] validator to require passed values to conform to an expected input.\n\nThis will require the argument value passed to this variable to match the `validator` regex before it will be executed.\n\nThe regex string is by default surrounded by `^...$` to match the full string. For example the `https?://\\w+` regex would be registered as `^https?://\\w+$`.\n\n[regex]: <https://docs.rs/regex/latest/regex/#syntax>",
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"additionalProperties": false
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"ShellScopeEntryAllowedArgs": {
|
"ShellScopeEntryAllowedArgs": {
|
||||||
"description": "A set of command arguments allowed to be executed by the webview API.\n\nA value of `true` will allow any arguments to be passed to the command. `false` will disable all arguments. A list of [`ShellScopeEntryAllowedArg`] will set those arguments as the only valid arguments to be passed to the attached command configuration.",
|
"description": "A set of command arguments allowed to be executed by the webview API.\n\nA value of `true` will allow any arguments to be passed to the command. `false` will disable all arguments. A list of [`ShellScopeEntryAllowedArg`] will set those arguments as the only valid arguments to be passed to the attached command configuration.",
|
||||||
"anyOf": [
|
"anyOf": [
|
||||||
@ -6333,6 +6305,34 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
"ShellScopeEntryAllowedArg": {
|
||||||
|
"description": "A command argument allowed to be executed by the webview API.",
|
||||||
|
"anyOf": [
|
||||||
|
{
|
||||||
|
"description": "A non-configurable argument that is passed to the command in the order it was specified.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "A variable that is set while calling the command from the webview API.",
|
||||||
|
"type": "object",
|
||||||
|
"required": [
|
||||||
|
"validator"
|
||||||
|
],
|
||||||
|
"properties": {
|
||||||
|
"validator": {
|
||||||
|
"description": "[regex] validator to require passed values to conform to an expected input.\n\nThis will require the argument value passed to this variable to match the `validator` regex before it will be executed.\n\nThe regex string is by default surrounded by `^...$` to match the full string. For example the `https?://\\w+` regex would be registered as `^https?://\\w+$`.\n\n[regex]: <https://docs.rs/regex/latest/regex/#syntax>",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"raw": {
|
||||||
|
"description": "Marks the validator as a raw regex, meaning the plugin should not make any modification at runtime.\n\nThis means the regex will not match on the entire string by default, which might be exploited if your regex allow unexpected input to be considered valid. When using this option, make sure your regex is correct.",
|
||||||
|
"default": false,
|
||||||
|
"type": "boolean"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"additionalProperties": false
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2023,6 +2023,14 @@
|
|||||||
"name"
|
"name"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"cmd": {
|
||||||
|
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2030,14 +2038,6 @@
|
|||||||
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
|
||||||
"cmd": {
|
|
||||||
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"additionalProperties": false
|
"additionalProperties": false
|
||||||
@ -2049,6 +2049,10 @@
|
|||||||
"sidecar"
|
"sidecar"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2057,10 +2061,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"sidecar": {
|
"sidecar": {
|
||||||
"description": "If this command is a sidecar command.",
|
"description": "If this command is a sidecar command.",
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
@ -2083,6 +2083,14 @@
|
|||||||
"name"
|
"name"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"cmd": {
|
||||||
|
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2090,14 +2098,6 @@
|
|||||||
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
"$ref": "#/definitions/ShellScopeEntryAllowedArgs"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
|
||||||
"cmd": {
|
|
||||||
"description": "The command name. It can start with a variable that resolves to a system base directory. The variables are: `$AUDIO`, `$CACHE`, `$CONFIG`, `$DATA`, `$LOCALDATA`, `$DESKTOP`, `$DOCUMENT`, `$DOWNLOAD`, `$EXE`, `$FONT`, `$HOME`, `$PICTURE`, `$PUBLIC`, `$RUNTIME`, `$TEMPLATE`, `$VIDEO`, `$RESOURCE`, `$LOG`, `$TEMP`, `$APPCONFIG`, `$APPDATA`, `$APPLOCALDATA`, `$APPCACHE`, `$APPLOG`.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"additionalProperties": false
|
"additionalProperties": false
|
||||||
@ -2109,6 +2109,10 @@
|
|||||||
"sidecar"
|
"sidecar"
|
||||||
],
|
],
|
||||||
"properties": {
|
"properties": {
|
||||||
|
"name": {
|
||||||
|
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
"args": {
|
"args": {
|
||||||
"description": "The allowed arguments for the command execution.",
|
"description": "The allowed arguments for the command execution.",
|
||||||
"allOf": [
|
"allOf": [
|
||||||
@ -2117,10 +2121,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"name": {
|
|
||||||
"description": "The name for this allowed shell command configuration.\n\nThis name will be used inside of the webview API to call this command along with any specified arguments.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"sidecar": {
|
"sidecar": {
|
||||||
"description": "If this command is a sidecar command.",
|
"description": "If this command is a sidecar command.",
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
@ -6290,34 +6290,6 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"ShellScopeEntryAllowedArg": {
|
|
||||||
"description": "A command argument allowed to be executed by the webview API.",
|
|
||||||
"anyOf": [
|
|
||||||
{
|
|
||||||
"description": "A non-configurable argument that is passed to the command in the order it was specified.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "A variable that is set while calling the command from the webview API.",
|
|
||||||
"type": "object",
|
|
||||||
"required": [
|
|
||||||
"validator"
|
|
||||||
],
|
|
||||||
"properties": {
|
|
||||||
"raw": {
|
|
||||||
"description": "Marks the validator as a raw regex, meaning the plugin should not make any modification at runtime.\n\nThis means the regex will not match on the entire string by default, which might be exploited if your regex allow unexpected input to be considered valid. When using this option, make sure your regex is correct.",
|
|
||||||
"default": false,
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
"validator": {
|
|
||||||
"description": "[regex] validator to require passed values to conform to an expected input.\n\nThis will require the argument value passed to this variable to match the `validator` regex before it will be executed.\n\nThe regex string is by default surrounded by `^...$` to match the full string. For example the `https?://\\w+` regex would be registered as `^https?://\\w+$`.\n\n[regex]: <https://docs.rs/regex/latest/regex/#syntax>",
|
|
||||||
"type": "string"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"additionalProperties": false
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"ShellScopeEntryAllowedArgs": {
|
"ShellScopeEntryAllowedArgs": {
|
||||||
"description": "A set of command arguments allowed to be executed by the webview API.\n\nA value of `true` will allow any arguments to be passed to the command. `false` will disable all arguments. A list of [`ShellScopeEntryAllowedArg`] will set those arguments as the only valid arguments to be passed to the attached command configuration.",
|
"description": "A set of command arguments allowed to be executed by the webview API.\n\nA value of `true` will allow any arguments to be passed to the command. `false` will disable all arguments. A list of [`ShellScopeEntryAllowedArg`] will set those arguments as the only valid arguments to be passed to the attached command configuration.",
|
||||||
"anyOf": [
|
"anyOf": [
|
||||||
@ -6333,6 +6305,34 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
"ShellScopeEntryAllowedArg": {
|
||||||
|
"description": "A command argument allowed to be executed by the webview API.",
|
||||||
|
"anyOf": [
|
||||||
|
{
|
||||||
|
"description": "A non-configurable argument that is passed to the command in the order it was specified.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "A variable that is set while calling the command from the webview API.",
|
||||||
|
"type": "object",
|
||||||
|
"required": [
|
||||||
|
"validator"
|
||||||
|
],
|
||||||
|
"properties": {
|
||||||
|
"validator": {
|
||||||
|
"description": "[regex] validator to require passed values to conform to an expected input.\n\nThis will require the argument value passed to this variable to match the `validator` regex before it will be executed.\n\nThe regex string is by default surrounded by `^...$` to match the full string. For example the `https?://\\w+` regex would be registered as `^https?://\\w+$`.\n\n[regex]: <https://docs.rs/regex/latest/regex/#syntax>",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"raw": {
|
||||||
|
"description": "Marks the validator as a raw regex, meaning the plugin should not make any modification at runtime.\n\nThis means the regex will not match on the entire string by default, which might be exploited if your regex allow unexpected input to be considered valid. When using this option, make sure your regex is correct.",
|
||||||
|
"default": false,
|
||||||
|
"type": "boolean"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"additionalProperties": false
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user