Sha256: 6f95c1b0f4371b71a7a7eea2a2ece9492f43f433d0c3c0b390bfb66c60d5d158
Contents?: true
Size: 1.76 KB
Versions: 2
Compression:
Stored size: 1.76 KB
Contents
# Dslh It define Hash as a DSL. [![Gem Version](https://badge.fury.io/rb/dslh.png)](http://badge.fury.io/rb/dslh) [![Build Status](https://drone.io/bitbucket.org/winebarrel/dslh/status.png)](https://drone.io/bitbucket.org/winebarrel/dslh/latest) ## Installation Add this line to your application's Gemfile: gem 'dslh' And then execute: $ bundle Or install it yourself as: $ gem install dslh ## Usage ```ruby require 'dslh' require 'pp' h = Dslh.eval do glossary do title "example glossary" GlossDiv do title "S" GlossList do GlossEntry do ID "SGML" SortAs "SGML" GlossTerm "Standard Generalized Markup Language" Acronym "SGML" Abbrev "ISO 8879:1986" GlossDef do para "A meta-markup language, used to create markup languages such as DocBook." GlossSeeAlso "GML", "XML" end GlossSee "markup" end end end end end pp h ``` ```ruby # h => {:glossary=> {:title=>"example glossary", :GlossDiv=> {:title=>"S", :GlossList=> {:GlossEntry=> {:ID=>"SGML", :SortAs=>"SGML", :GlossTerm=>"Standard Generalized Markup Language", :Acronym=>"SGML", :Abbrev=>"ISO 8879:1986", :GlossDef=> {:para=> "A meta-markup language, used to create markup languages such as DocBook.", :GlossSeeAlso=>["GML", "XML"]}, :GlossSee=>"markup"}}}}} ``` ## Contributing 1. Fork it ( http://github.com/<my-github-username>/dslh/fork ) 2. Create your feature branch (`git checkout -b my-new-feature`) 3. Commit your changes (`git commit -am 'Add some feature'`) 4. Push to the branch (`git push origin my-new-feature`) 5. Create new Pull Request
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dslh-0.1.1 | README.md |
dslh-0.1.0 | README.md |