Awesome
jekyll-roman
A liquid filter for Jekyll that converts numbers into Roman numerals.
Installation
- Add
gem 'jekyll-roman'
to your site’s Gemfile and runbundle
- Add the following to your site’s
_config.yml
:
gems:
- jekyll-roman
Usage
This filter takes any given whole number and converts it. Any other types of string are ignored. For example, if you wish to display the year in your site’s copyright statement as roman numerals, you would write the following:
<h1>© {{ site.time | date:"%Y" | roman }}</h1>
Testing
bundle install
bundle exec rake spec
Contributing
- Fork the project
- Create a descriptively named feature branch
- Add your feature
- Submit a pull request
Acknowledgements
Code based on that found in this discussion on Stack Overflow. If you know of a better way of achieving the same result, please let me know!