Quick and dirty mapper of cite urns to standard abbreviations
Add this line to your application's Gemfile:
gem 'cite_mapper'
And then execute:
$ bundle
Or install it yourself as:
$ gem install cite_mapper
Run rackup
to start a webserver (its port defaults to 9292).
At the moment the server will only respond to two GET methods.
If you want to know what urn:cts:greekLit:tlg0007.tlg015.perseus-eng1:16.1
means, you can ask the server
http://localhost:9292/find_cite?cite=urn%3Acts%3AgreekLit%3Atlg0007.tlg015.perseus-eng1%3A16.1
and it will respond in JSON:
{ "author" : "Plut.", "work" : "Alc.", "section" : "16.1" }
If you want to know what Xen. Cyrop. 5.3.11-17
means, you can ask the server
http://localhost:9292/find_abbr?abbr=Xen.%20Cyrop.%205.3.11-17`
and it will respond in JSON:
{"urn":"urn:cts:greekLit:tlg0032:tlg007:5.3.11-5.3.17"}
- Fork it ( https://github.com/[my-github-username]/cts_mapper/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request