Skip to content

Instantly share code, notes, and snippets.

@bengotow
Created December 2, 2020 18:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bengotow/0b700e7d0367750cb31eaf697f865d70 to your computer and use it in GitHub Desktop.
Save bengotow/0b700e7d0367750cb31eaf697f865d70 to your computer and use it in GitHub Desktop.
Complex Example YAML
foo1: "{{ variable }}/additional/string/literal"
foo2: "{{ variable }}\\backslashes\\are\\also\\special\\characters"
foo3: "even if it's just a string literal it must all be quoted"
foo4: "a \t TAB and a \n NEWLINE"
foo5: "somebody said I should put a colon here: so I did"
wild: this } is [ all , valid
flow_mapping: { key: "you { should [ use , quotes here" }
inline_array: [123, 5123,1325, "123z", zzz1, 12-.txt, 5.123, -51.23]
inline_complex_1: [{asd: 123}, {b: 2}]
windows_drive: "c:"
windows_path: c:\windows
name: Martin D'vloper
job: Developer
number: -4.123
employed: True
foods:
- Apple
- Orange
- Strawberry
- Mango
languages:
perl: Elite
python: Elite
pascal: Lame
education: |
4 GCSEs
3 A-Levels
BSc in the Internet of Things
array_of_objects:
- object:
value: 1
other: 2
- second:
value: 3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment