I'm writing a simple web scraper in Common Lisp (SBCL) as a learning exercise, & would like to sort by date. To do this, I'll need to parse dates in the format "MM/DD/YYYY" into universal time.
I could simply tokenise the string & pass the bits into encode-universal-time
, but I figure that there must be a built-in function (or popular third-party package) for date parsing. I'd greatly appreciate someone recommending one :-)
This answer is very late but the local-time library is featureful and widely used. It is based on the article The long painful history of time.
It supports :
See the net-telent-date and simple-date-time libraries for Common Lisp. The former has a parse-time
function you can use (see parse-time.lisp). Both are included in the QuickLisp library collection.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With