ref: b8289bc2614da6b202a3eaa29daf2ed00c65594d
converter/server/vendor/mustangostang/spyc/spyc.yaml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 |
# # S P Y C # a simple php yaml class # # authors: [vlad andersen (vlad.andersen@gmail.com), chris wanstrath (chris@ozmm.org)] # websites: [http://www.yaml.org, http://spyc.sourceforge.net/] # license: [MIT License, http://www.opensource.org/licenses/mit-license.php] # copyright: (c) 2005-2006 Chris Wanstrath, 2006-2014 Vlad Andersen # # spyc.yaml - A file containing the YAML that Spyc understands. --- # Mappings - with proper types String: Anyone's name, really. Int: 13 BadHex: f0xf3 Hex: 0xf3 True: true False: false Zero: 0 Null: NULL NotNull: 'null' NotTrue: 'y' NotBoolTrue: 'true' NotInt: '5' Float: 5.34 Negative: -90 SmallFloat: 0.7 NewLine: \n QuotedNewLine: "\n" # A sequence - PHP Class - Basic YAML Loader - Very Basic YAML Dumper # A sequence of a sequence - - YAML is so easy to learn. - Your config files will never be the same. # Sequence of mappings - cpu: 1.5ghz ram: 1 gig os : os x 10.4.1 # Mapped sequence domains: - yaml.org - php.net # A sequence like this. - program: Adium platform: OS X type: Chat Client # A folded block as a mapped value no time: > There isn't any time for your tricks! Do you understand? # A literal block as a mapped value some time: | There is nothing but time for your tricks. # Crazy combinations databases: - name: spartan notes: - Needs to be backed up - Needs to be normalized type: mysql # You can be a bit tricky "if: you'd": like # Inline sequences - [One, Two, Three, Four] # Nested Inline Sequences - [One, [Two, And, Three], Four, Five] # Nested Nested Inline Sequences - [This, [Is, Getting, [Ridiculous, Guys]], Seriously, [Show, Mercy]] # Inline mappings - {name: chris, age: young, brand: lucky strike} # Nested inline mappings - {name: mark, age: older than chris, brand: [marlboro, lucky strike]} # References -- they're shaky, but functional dynamic languages: &DLANGS - Perl - Python - PHP - Ruby compiled languages: &CLANGS - C/C++ - Java all languages: - *DLANGS - *CLANGS # Added in .2.2: Escaped quotes - you know, this shouldn't work. but it does. - 'that''s my value.' - 'again, that\'s my value.' - "here's to \"quotes\", boss." # added in .2.3 - {name: "Foo, Bar's", age: 20} # Added in .2.4: bug [ 1418193 ] Quote Values in Nested Arrays - [a, ['1', "2"], b] # Add in .5.2: Quoted new line values. - "First line\nSecond line\nThird line" # Added in .2.4: malformed YAML all javascripts: [dom1.js, dom.js] # Added in .2 1040: Ooo, a numeric key! # And working comments? Wow! Colons in comments: a menace (0.3). hash_1: Hash #and a comment hash_2: "Hash #and a comment" "hash#3": "Hash (#) can appear in key too" float_test: 1.0 float_test_with_quotes: '1.0' float_inverse_test: 001 a_really_large_number: 115792089237316195423570985008687907853269984665640564039457584007913129639936 # 2^256 int array: [ 1, 2, 3 ] array on several lines: [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19 ] morelesskey: "<value>" array_of_zero: [0] sophisticated_array_of_zero: {rx: {tx: [0]} } switches: - { row: 0, col: 0, func: {tx: [0, 1]} } empty_sequence: [ ] empty_hash: { } special_characters: "[{]]{{]]" asterisks: "*" empty_key: : key: value trailing_colon: "foo:" multiline_items: - type: SomeItem values: [blah, blah, blah, blah] ints: [2, 54, 12, 2143] many_lines: | A quick fox jumped over a lazy dog werte: 1: nummer 1 0: Stunde 0 noindent_records: - record1: value1 - record2: value2 "a:1": [1000] "a:2": - 2000 a:3: [3000] complex_unquoted_key: a:b:''test': value array with commas: ["0","1"] invoice: ["Something", "", '', "Something else"] quotes: ['Something', "Nothing", 'Anything', "Thing"] # [Endloop] endloop: | Does this line in the end indeed make Spyc go to an infinite loop? |