i Need a Feature or a funtions to read and write to yml files similar to the $readini $read and /write funktion in Mirc.
The reason why I need this is because mirc doesn't take spaces and indentations or tabs etc into account and so it's not possible to set a variable in the following form.
An example:
In a Test.yml
There is the following entry.
BlackListedBlocks:
- BEDROCK
- OBSIDIAN
- DIAMOND
- DIORITE
I would have to be able to address the section using the new function, which is similar to the $readini function.
The new function would have to be called as follows.
$readyml(file, Section)
So now if I use $readyml(test.yml, BlacklistedBlocks)
The input should reflect the following, taking into account the indentation and spaces.
The output should then be:
- BEDROCK
- OBSIDIAN
- DIAMOND
- DIORITE
It would be nice if someone could put something like that together for me.
I can't solve this using $read and $readini because readini only recognizes a section marked with [] and 2. doesn't take spaces or indents or tabs into account
/set %var also doesn't work because it also eats up the spaces.