Date and Timeby Mike Pavone
I have this bad habit of having a burst of productivity, setting a tentative schedule based on said productivity and then having a lull in my productivity causing me to totally miss my goal. I haven't really made much progress on the compiler since my last post. I have made some progress on some other areas though, the biggest one being the addition of a Date Time object. There's been a Unix Time worker in the repository version of the interpreter for a while now, but if you wanted to do anything useful with the values it returned you were pretty much on your own. Now date.rhope has some basic code for converting those values into a more useful format and formatting into human readable strings.
For instance, you can do:
[Now]Format["M/D/Y h:m:s a"]
and you would get backsomething like
12/4/2009 06:53:00 AM
There also some convience functions for common date formats like:
which will return a date in the preferred format specified by RFC 2616 (HTTP 1.1) like so:
Fri, 04 Dec 2009 06:53:00 GMT
The code needs a fair amount of work (leap year code isn't quite right, leap seconds aren't handled, no support for date math, etc.), but it's a start. For now it should be good enough for me to finally add dates to my blog entries and add caching to my simple Rhope webserver.
I'm actually planning on making a number of other enhancements to the webserver this month. The shared hosting provider that I host the main retrodev site on has raised their rates and Linux VPS hosting has gotten quite cheap so the plan is to consolidate the Rhope website and the main retrodev site onto a single VPS. I'd like to avoid having to run multiple webservers so I need to improve support for static content (thus the caching) and add support for FastCGI or something similar for the repository.
Hopefully this will result in a more stable (Linux on a proper server rather than Syllable Desktop on a desktop class machine with no case) and faster loading site for Rhope as well as simplifying my hosting a bit. If I'm lucky I'll even save a little money by reducing my home electric usage.