DannyBen/bashly

View on GitHub
schemas/settings.json

Summary

Maintainability
Test Coverage
{
    "$schema": "https://json.schemastore.org/metaschema-draft-07-unofficial-strict.json",
    "definitions": {
        "color": {
            "oneOf": [
                {
                    "type": "string",
                    "examples": [
                        "red",
                        "green",
                        "yellow",
                        "blue",
                        "magenta",
                        "cyan",
                        "bold",
                        "underlined",
                        "red_bold",
                        "green_bold",
                        "yellow_bold",
                        "blue_bold",
                        "magenta_bold",
                        "cyan_bold",
                        "red_underlined",
                        "green_underlined",
                        "yellow_underlined",
                        "blue_underlined",
                        "magenta_underlined",
                        "cyan_underlined"
                    ]
                },
                {
                    "type": "null"
                }
            ]
        }
    },
    "title": "settings",
    "description": "Settings of the current application\nhttps://bashly.dannyb.co/usage/settings/#settings",
    "type": "object",
    "properties": {
        "source_dir": {
            "title": "source dir",
            "description": "The path containing the bashly source files\nhttps://bashly.dannyb.co/usage/settings/#source_dir",
            "type": "string",
            "minLength": 1,
            "default": "src"
        },
        "config_path": {
            "title": "config path",
            "description": "The path to bashly.yml\nhttps://bashly.dannyb.co/usage/settings/#config_path",
            "type": "string",
            "minLength": 1,
            "default": "%{source_dir}/bashly.yml"
        },
        "target_dir": {
            "title": "target dir",
            "description": "The path to use for creating the bash script\nhttps://bashly.dannyb.co/usage/settings/#target_dir",
            "type": "string",
            "minLength": 1,
            "default": "."
        },
        "lib_dir": {
            "title": "lib dir",
            "description": "The path to use for common library files, relative to source_dir\nhttps://bashly.dannyb.co/usage/settings/#lib_dir",
            "type": "string",
            "minLength": 1,
            "default": "lib"
        },
        "commands_dir": {
            "title": "commands dir",
            "description": "The path to use for command files, relative to source_dir\nhttps://bashly.dannyb.co/usage/settings/#commands_dir",
            "oneOf": [
                {
                    "type": "string",
                    "minLength": 1
                },
                {
                    "type": "null"
                }
            ]
        },
        "strict": {
            "title": "strict",
            "description": "Configure the bash options that will be added to the initialize function\nhttps://bashly.dannyb.co/usage/settings/#strict",
            "oneOf": [
                {
                    "type": "boolean"
                },
                {
                    "type": "string",
                    "examples": [
                        "set -o pipefail"
                    ]
                }
            ],
            "default": false
        },
        "tab_indent": {
            "title": "tab indent",
            "description": "Whether to use tabs or spaces in the the generated script\nhttps://bashly.dannyb.co/usage/settings/#tab_indent",
            "type": "boolean",
            "default": false
        },
        "compact_short_flags": {
            "title": "compact short flags",
            "description": "Whether to expand -abc to -a -b -c in the input line\nhttps://bashly.dannyb.co/usage/settings/#compact_short_flags",
            "type": "boolean",
            "default": true
        },
        "conjoined_flag_args": {
            "title": "conjoined flag args",
            "description": "Whether to expand --flag=value to --flag value in the input line\nhttps://bashly.dannyb.co/usage/settings/#conjoined_flag_args",
            "type": "boolean",
            "default": true
        },
        "env": {
            "title": "env",
            "description": "Whether to include development related comments in the generated script\nhttps://bashly.dannyb.co/usage/settings/#env",
            "type": "string",
            "enum": [
                "development",
                "production"
            ],
            "default": "development"
        },
        "partials_extension": {
            "title": "partials extension",
            "description": "The extension to use when reading/writing partial script snippets\nhttps://bashly.dannyb.co/usage/settings/#partials_extension",
            "type": "string",
            "minLength": 1,
            "default": "sh"
        },
        "usage_colors": {
            "title": "usage colors",
            "description": "Enable and configure colorful output for --help\nhttps://bashly.dannyb.co/usage/settings/#usage_colors",
            "type": "object",
            "properties": {
                "caption": {
                    "title": "caption",
                    "description": "Color for captions\nhttps://bashly.dannyb.co/usage/settings/#usage_colors",
                    "$ref": "#/definitions/color"
                },
                "command": {
                    "title": "command",
                    "description": "Color for commands\nhttps://bashly.dannyb.co/usage/settings/#usage_colors",
                    "$ref": "#/definitions/color"
                },
                "arg": {
                    "title": "arg",
                    "description": "Color for positional arguments\nhttps://bashly.dannyb.co/usage/settings/#usage_colors",
                    "$ref": "#/definitions/color"
                },
                "flag": {
                    "title": "flag",
                    "description": "Color for flags\nhttps://bashly.dannyb.co/usage/settings/#usage_colors",
                    "$ref": "#/definitions/color"
                },
                "environment_variable": {
                    "title": "environment variable",
                    "description": "Color for env environment variables\nhttps://bashly.dannyb.co/usage/settings/#usage_colors",
                    "$ref": "#/definitions/color"
                }
            },
            "additionalProperties": false
        }
    },
    "additionalProperties": false
}