Skip to content

geckocircle/copyright_date_range

Repository files navigation

CopyrightDateRange

This is a simple gem that provides a single helper method:

copyright_date_range(start_year)

Simply call it in a layout file as such:

.copyright 
  Copyright © #{copyright_date_range(2011)} MyCoolCompany.  All Rights Reserved.

If it is currently 2012, this will yield:

Copyright © 2011 - 2012 MyCoolCompany. All Rights Reserved.

If it is currently 2011, it would simply yield:

Copyright © 2011 MyCoolCompany. All Rights Reserved.

Installation

If you use Bundler, you can install this gem by including it in your Gemfile:

gem 'copyright_date_range', "~> 0.1.1"

If you'd like to live on the wild side, and use the latest GitHub version:

gem 'copyright_date_range', :git => "git://github.com/geckocircle/copyright_date_range.git"

License

Copyright (C) 2012 Dave Rosborough.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

Generate a year range from a given date to today's year for copyright statements.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages