End of Life Ruby 3.0 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
instance method
Psych::Emitter#canonical=
emitter.canonical = true
ext/psych/psych_emitter.c
View on GitHub ↗
static VALUE set_canonical(VALUE self, VALUE style)
{
yaml_emitter_t * emitter;
TypedData_Get_Struct(self, yaml_emitter_t, &psych_emitter_type, emitter);
yaml_emitter_set_canonical(emitter, Qtrue == style ? 1 : 0);
return style;
}
Set the output style to canonical, or not.