Sha256: 5690792179133bf8089040519a96d983d8db62af0b0c60b58f932fd2c28a2bee
Contents?: true
Size: 471 Bytes
Versions: 1
Compression:
Stored size: 471 Bytes
Contents
# coding: utf-8 # $Id: date.rb 120 2009-02-09 08:22:25Z yuyakato $ require "rubygems" require "kagemusha/date" p Date.today.strftime("%Y-%m-%d") #=> today # Normal Style. musha = Kagemusha::Date.on(2007, 1, 1) musha.swap { p Date.today.strftime("%Y-%m-%d") #=> 2007-01-01 } p Date.today.strftime("%Y-%m-%d") #=> today # Block Style. Kagemusha::Date.on(2007, 1, 1) { p Date.today.strftime("%Y-%m-%d") #=> 2007-01-01 } p Date.today.strftime("%Y-%m-%d") #=> today
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
kagemusha-0.0.8 | examples/date.rb |