Sha256: 58527144cffcc5bc1a634d7327cfe7b1fd7b9d251edbb6df5eef005f8349550e
Contents?: true
Size: 354 Bytes
Versions: 2
Compression:
Stored size: 354 Bytes
Contents
# encoding: utf-8 module Nanoc::Extra::TimeExtensions # @return [String] The time in an ISO-8601 date format. def to_iso8601_date strftime('%Y-%m-%d') end # @return [String] The time in an ISO-8601 time format. def to_iso8601_time getutc.strftime('%Y-%m-%dT%H:%M:%SZ') end end class Time include Nanoc::Extra::TimeExtensions end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
nanoc-3.8.0 | lib/nanoc/extra/core_ext/time.rb |
nanoc-3.7.5 | lib/nanoc/extra/core_ext/time.rb |