Description

A DateTime formatting library for D

Package Information

Version0.1.0 (2016-Nov-11)
Homepagehttps://github.com/cmays90/datetimeformat
Repositoryhttps://github.com/cmays90/datetimeformat
LicenseZlib
CopyrightCopyright © 2016, Chris Mays
AuthorsChris Mays
Registered byChris M
Dependenciesnone

Installation

To use this package, put the following dependency into your project's dependencies section:

dub.json
dub.sdl

Readme

datetimeformat

A DateTime formatting library for D

#Sample Usage

import datetimeformat;
import std.stdio;
import datetime;

void main()
{
    SysTime dt = SysTime(DateTime(2005, 9, 8, 16, 51, 9), dur!"msecs"(427));
    writeln(dt.format("yyyy-mm-dd HH:ii:ss.FFF")); //"2005-09-08 16:51:09.427"
}

#Acknowledgments

This is based on Stewart's Utility Library datetime and datetimeformat.

It has been adapated to use Phobo's DateTime object instead of SUL's datetime, removing a dependency.

Notably missing in this version is the ability to have and utilize "collapsable" tags.

Available versions

0.1.0 ~master