Skip to content

Converter Configuration

The Converter Configuration describe here is shared across all dialects and allows you to define settings for the conversion process. These settings include the output file extension, user template paths, template configurations, template tag filters, and node filters. The configuration class is designed to work with all dialects.

Configuration Fields

Field Description Default Value Localizable Environment Variable
default_output_extension Specifies the default output file extension for the converted files. ".out"1 No
user_template_paths List of folders containing user-defined templates to make available for conversion. [ ] No
template_configs List of Template Configs. [ ] No
template_tag_filter filter configuration for template tags to include or exclude from matching. List of Template Tag Filter Configs No
node_filter List of Node Filter Configs which determine the nodes to be included or excluded from rendering. [ ] No
render_unsupported_output_as_comment Whether partial results of conversion of unsupported nodes should be included in conversion result as comments. true No

Example Configuration

Here is an example configuration in YAML format:

converter:
    default_output_extension: ".sql"
    user_template_paths:
        - /path/to/your/templates/folder
    template_configs:
        ... # see template.md for more information
    template_tag_filter:
        exclude: ["runtime"]
    node_filter:
        ... # see node_filter.md for more information

By configuring these settings, you can customize the conversion process to better suit your specific project requirements. The General Converter Configuration enables you to define how your code is transformed, giving you greater control over the output.

Template Tag Filter Configuration

Option Description Default Value Data Type
exclude List of tags to exclude from rendering. [] list
include List of tags to include in rendering. [] list

  1. The default output extension for a given dialect may be different. Refer to dialect-specific documentation for more information.