Sha256: 7b420e79d1bdaf671b8f155a752bb5782ff266e602fa93eb53fc66948c0eb1ec

Contents?: true

Size: 546 Bytes

Versions: 3

Compression:

Stored size: 546 Bytes

Contents

#!/usr/bin/env ruby

require_relative "../lib/jekyll-timeago/core"
include Jekyll::Timeago::Core

help_message = <<END
Usage:

  jekyll-timeago <from_date> [to_date]

Notes:
        [to_date] Optional, defaults to current date

Options:
        --help, -h  Print this message
        --console   Start an interactive session with jekyll-timeago included
END

if ARGV.empty? || ARGV.include?("--help") || ARGV.include?("-h")
  puts help_message
elsif ARGV.include? "--console"
  require "irb"
  ARGV.clear
  IRB.start
else
  puts timeago *ARGV
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
jekyll-timeago-0.9.2 bin/jekyll-timeago
jekyll-timeago-0.9.1 bin/jekyll-timeago
jekyll-timeago-0.9.0 bin/jekyll-timeago