Class: Hash
- Inherits:
-
Object
- Object
- Hash
- Defined in:
- lib/git_store/handlers.rb
Overview
This fix ensures sorted yaml maps.
Instance Method Summary collapse
Instance Method Details
#to_yaml(opts = {}) ⇒ Object
4 5 6 7 8 9 10 11 12 |
# File 'lib/git_store/handlers.rb', line 4 def to_yaml( opts = {} ) YAML::quick_emit( object_id, opts ) do |out| out.map( taguri, to_yaml_style ) do |map| sort_by { |k, v| k.to_s }.each do |k, v| map.add( k, v ) end end end end |