Skip to content

Commit 7734e7a

Browse files
committed
fix: include title in the generated json schema files
1 parent 870d59e commit 7734e7a

File tree

7 files changed

+9
-0
lines changed

7 files changed

+9
-0
lines changed

docs/schemas/config_schema.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"$schema": "http://json-schema.org/draft-07/schema#",
33
"$id": "https://flowexec.io/schemas/config_schema.json",
4+
"title": "Config",
45
"description": "User Configuration for the Flow CLI.\nIncludes configurations for workspaces, templates, I/O, and other settings for the CLI.\n\nIt is read from the user's flow config directory:\n- **MacOS**: `$HOME/Library/Application Support/flow`\n- **Linux**: `$HOME/.config/flow`\n- **Windows**: `%APPDATA%\\flow`\n\nAlternatively, a custom path can be set using the `FLOW_CONFIG_PATH` environment variable.\n",
56
"type": "object",
67
"required": [
@@ -120,6 +121,7 @@
120121
"default": "default",
121122
"enum": [
122123
"default",
124+
"everforest",
123125
"dark",
124126
"light",
125127
"dracula",

docs/schemas/flowfile_schema.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"$schema": "http://json-schema.org/draft-07/schema#",
33
"$id": "https://flowexec.io/schemas/flowfile_schema.json",
4+
"title": "FlowFile",
45
"description": "Configuration for a group of Flow CLI executables. The file must have the extension `.flow` in order to be discovered \nby the CLI. It's configuration is used to define a group of executables with shared metadata (namespace, tags, etc).\nA workspace can have multiple flow files located anywhere in the workspace directory\n",
56
"type": "object",
67
"definitions": {
@@ -30,6 +31,7 @@
3031
]
3132
},
3233
"Executable": {
34+
"title": "Executable",
3335
"description": "The executable schema defines the structure of an executable in the Flow CLI.\nExecutables are the building blocks of workflows and are used to define the actions that can be performed in a workspace.\n",
3436
"type": "object",
3537
"required": [

docs/schemas/template_schema.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"$schema": "http://json-schema.org/draft-07/schema#",
33
"$id": "https://flowexec.io/schemas/template_schema.json",
4+
"title": "Template",
45
"description": "Configuration for a flowfile template; templates can be used to generate flow files.",
56
"type": "object",
67
"required": [

docs/schemas/workspace_schema.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"$schema": "http://json-schema.org/draft-07/schema#",
33
"$id": "https://flowexec.io/schemas/workspace_schema.json",
4+
"title": "Workspace",
45
"description": "Configuration for a workspace in the Flow CLI.\nThis configuration is used to define the settings for a workspace.\nEvery workspace has a workspace config file named `flow.yaml` in the root of the workspace directory.\n",
56
"type": "object",
67
"definitions": {

tools/docsgen/json.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ func generateJSONSchemas() {
3131
schema.MergeSchemas(s, value, fn, sm)
3232
}
3333

34+
s.Title = fn.Title()
3435
schemaJSON, err := json.MarshalIndent(s, "", " ")
3536
if err != nil {
3637
panic(err)

tools/docsgen/schema/schema.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ type JSONSchema struct {
2323
Schema string `json:"$schema,omitempty" yaml:"$schema,omitempty"`
2424
Ref Ref `json:"$ref,omitempty" yaml:"$ref,omitempty"`
2525
ID string `json:"$id,omitempty" yaml:"$id,omitempty"`
26+
Title string `json:"title,omitempty" yaml:"title,omitempty"`
2627
Description string `json:"description,omitempty" yaml:"description,omitempty"`
2728
Type string `json:"type,omitempty" yaml:"type,omitempty"`
2829
Required []string `json:"required,omitempty" yaml:"required,omitempty"`

types/config/config.gen.go

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)