tree-sitter-caddy

module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 2, 2026 License: GPL-3.0

README

tree-sitter-caddy

Functionality

  • Global options
    • Option name
    • Option value
    • Block options
  • Server
    • Protocol, domain, port in any order
    • Multiple addresses
    • No need for {} when only one server
    • Environment variables in address ex. {$DOMAIN:localhost}
  • Tokens and quotes
    • directive "simple string"
    • directive ""simple string""
    • directive ""simple string""
    • directive "quoted string"
    • directive "miltiline string"
    • Heredocs
      example.com {
          respond <<HTML
              <html>
                <head><title>Foo</title></head>
                <body>Foo</body>
              </html>
              HTML 200
      }
      
  • Matchers
    • /path
    • *
    • @post
  • Placeholders
  • Snippets
    • import directive
  • Named Routes
  • Comments
  • Environment variables
  • Types support
    • string
    • quoted strings
    • numerical
    • boolean
    • time (1s, 1m, 1h, 1d)
    • size (1KB, 1MiB)
  • Expressions
    • After-placeholder expressions ({method}.startsWith("P"))
    • Expressions (header({'Connection':'*Upgrade*','Upgrade':'websocket'})
  • Special cases
    • Placeholders can't be found in random string (redir https://www.{host}{uri})

Directories

Path Synopsis
bindings
go

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL