ddfreyne changed the topic of #nanoc to: 3.6.3 (apr 24th) | web http://nanoc.ws/ | repo http://bit.ly/XE6e3G | issues http://bit.ly/VfXaSV | forum http://ho.io/n-discuss | irclog http://irclog.whitequark.org/nanoc
louquillio has quit [Remote host closed the connection]
louquillio has joined #nanoc
louquillio has quit [Remote host closed the connection]
bghost has quit [Read error: Operation timed out]
bghost has joined #nanoc
louquillio has joined #nanoc
Palmik has joined #nanoc
<Palmik> Hi guys. Does anyone have routing setup so that posts whose name has format like <yyyy>-<mm>-<dd>-<title>.<suffix> are routed <yyyy>/<mm>/<dd>/<title>.html
cDlm has quit [Ping timeout: 248 seconds]
cDlm has joined #nanoc
pavelkunc has joined #nanoc
<ddfreyne> Palmik: In a routing rule, you can parse item.identifier (with a regex for instance)
<ddfreyne> sec…
<ddfreyne> >> '/posts/2013-05-18-blah/'.sub(%r{^/posts/(\d{4})-(\d{2})-(\d{2})-(.*)/}, '/posts/\1/\2/\3/\4.html')
<ddfreyne> => "/posts/2013/05/18/blah.html"
<Palmik> Ah, nice. Thanks.
pavelkunc has quit [Quit: Leaving.]
pavelkunc has joined #nanoc
pavelkunc has quit [Quit: Leaving.]
pavelkunc has joined #nanoc
alerante has quit [Remote host closed the connection]
<ddfreyne> Hmmm.
<ddfreyne> I’m unifying items and layouts, because both of them have content, attributes and an identifier
<ddfreyne> But I cannot come up with a decent name. I had ContentPiece, but that sucks because it is confusing with the content/ dir
<darix> ddfreyne: Nanoc::Snippet
<cDlm> I'd keep item, some of them just happen to be used as layouts
bghost has quit [Quit: leaving]
bghost has joined #nanoc
louquillio has quit [Remote host closed the connection]