How to use the shyaml.ShyamlSafeDumper function in shyaml

To help you get started, we’ve selected a few shyaml examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github 0k / shyaml / shyaml.py View on Github external
def yaml_dump(value):
    """Returns a representation of values directly usable by bash.

    Literal types are quoted and safe to use as YAML.

    """
    return yaml.dump(value, default_flow_style=False,
                     Dumper=ShyamlSafeDumper)