{
  "id": "cookcli",
  "name": "CookCLI",
  "homepage": "https://github.com/cooklang/cookcli",
  "description": "Command line tools for working with Cooklang recipes.",
  "executables": [
    "cook"
  ],
  "platforms": [
    "macos",
    "linux"
  ],
  "dotfiles": {
    "paths": [
      "~/.config/cooklang/",
      "~/Library/Application Support/cook/"
    ],
    "secret": []
  },
  "commands": {
    "format": 1,
    "label": "CookCLI",
    "description": "Serve a folder of .cook recipes as a local web UI with `cook server`. Host binding, proxy and CORS options are left out except the origin list.",
    "quality": "ai-draft",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": true,
      "short_attached": true,
      "short_bundles": false
    },
    "subcommand": [
      {
        "path": [
          "server"
        ],
        "label": "Run the recipe server",
        "source": [
          {
            "id": "src",
            "kind": "help",
            "url": "https://github.com/cooklang/cookcli/blob/main/src/server/mod.rs",
            "revision": "main 2026-10",
            "evidence": "    /// Root directory containing your recipe files\n    #[arg(short = 'p', long, default_value_t = 9080)]  // --port, -p\n    /// Port number for the HTTP server\n    /// Automatically open the web interface in your default browser\n    #[arg(long, default_value_t = false)]\n    open: bool,  // --open\n    /// Origin allowed to make cross-origin browser requests (repeatable)\n    /// Pass once per origin, e.g. --cors-origin http://localhost:3000. By\n    /// --url-prefix \"/cook\" will make the server available at /cook/ instead\n"
          }
        ],
        "field": [
          {
            "id": "base_path",
            "label": "Recipe directory",
            "type": "path",
            "position": 0,
            "path": {
              "kind": "directory",
              "role": "input"
            },
            "sources": [
              "src"
            ]
          },
          {
            "id": "port",
            "label": "Port",
            "type": "integer",
            "option": [
              "--port",
              "-p"
            ],
            "sources": [
              "src"
            ]
          },
          {
            "id": "open",
            "label": "Open in browser",
            "type": "boolean",
            "option": [
              "--open"
            ],
            "sources": [
              "src"
            ]
          },
          {
            "id": "url_prefix",
            "label": "URL prefix",
            "description": "Subpath behind a reverse proxy; must start with /.",
            "type": "string",
            "option": [
              "--url-prefix"
            ],
            "sources": [
              "src"
            ]
          },
          {
            "id": "cors_origin",
            "label": "Allowed CORS origins",
            "type": "url",
            "option": [
              "--cors-origin"
            ],
            "multiple": true,
            "sources": [
              "src"
            ]
          }
        ],
        "task": [
          {
            "id": "serve",
            "label": "Serve recipes",
            "set": {
              "open": [
                true
              ]
            },
            "fields": [
              "base_path",
              "port",
              "open"
            ],
            "required": []
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "base_path",
              "port",
              "open"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "url_prefix",
              "cors_origin"
            ]
          }
        ]
      }
    ]
  }
}
