May 2019 Archives

Reusing data with YAML Anchors, Aliases and Merge Keys

I just added a feature called "Merge Keys" to YAML::PP. No Perl YAML module supports this so far. You can merge mappings defined elsewhere in your YAML document into other mappings with that. Here is a short example:

---
defaults: &defaults
  A: 1
  B: 2
mapping:
  << : *defaults
  A: 23
  C: 99

# same as:
mapping:
  B: 2
  A: 23
  C: 99

If you don't know the &defaults/*defaults notation, here follows a basic introduction before I explain the merge keys.

YAML and more at the Perl Toolchain Summit 2019

This year, I was happy to hear I would be invited again to the Perl Toolchain Summit, an annual event with about 30-35 people hacking four days on toolchain related stuff, improving user experience.

This time it was held in Marlow, a small city two hours from London, in an old abbey which was beautiful (but cold!).

About tinita

user-pic just another perl punk,