sidebar: use a logarithmic tagcloud scaling Instead of linearly scaling the tagcloud entries based on their counts, scale it based on the 2 times the natural log of the count. This gives more weight to lower count tags, making the whole cloud looking "denser". Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
theme: turn the shipped theme into a proper theme example It is silly to ship my blahg's theme with the software. For a couple of years, it's been possible to specify the theme directory via the theme-dir config option so there is no harm generalizing the shipped theme and encouraging users to copy it and tweak it to taste. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
fmt3: remove trailing slashes from generated html The trailing slashes in some of the tags were a XHTML thing that was acceptable with HTML 4. Since both of those are a thing of the past, the w3 validator warns about these slashes. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
theme: remove trailing slashes from html The trailing slashes in some of the tags were a XHTML thing that was acceptable with HTML 4. Since both of those are a thing of the past, the w3 validator warns about these slashes. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
template: use %define api.pure instead of %pure-parser %pure-parser got deprecated a number of years ago. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
post fmt3: use %define api.pure instead of %pure-parser %pure-parser got deprecated a number of years ago. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
Added tag v4.8 for changeset 5306db73b02f Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
utils: clear struct tm before calling strptime Some strptime implementations clear the struct tm while others do not. Since we want zeros for everything other than the year, month, day, hour, and minute, we need to explicitly memset the struct. This wasn't noticed before since illumos libc falls into the category of zeroes-tm-for-you implementations. On systems that do not zero struct tm automatically, various random values end up in tm_sec which causes the subsequent mktime to return a value that doesn't represent the passed in string's meaning. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
samples: document tagcloud-min-count Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
config: default URL should include http scheme Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
static: make URI prefix configurable This changes the definition of the base-url config knob to be a list instead of a cons. The list should have one or two items: the scheme+host+port portion and the URI prefix portion. The migration is simple - just replace: (base-url . "http://example.com") With: (base-url "http://example.com") That is, the cons cell turned into a list. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
doc: fix incorrect example of post.lisp listed usage The listed post.lisp option takes a single argument, not a list. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
sidebar: make the minimum tagcloud count configurable Instead of hardcoding the decision that a tag must have at least 2 posts for it to show up in the tag cloud, let the admin decide what is a good cutoff. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
nvl_alloc returns a negated errno on error Checking for NULL is useless since nvl_alloc never returns NULL. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
docs: document the fmt 3 commands and environments Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
README: gcc or clang is a dependency Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
post: set post title to "Undefined" by default This fixes a NULL-pointer dereference when no title was provided. (All post formats were affected.) Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
post fmt 2: reintroduce raw html format support This time, however, the implementation is much simpler and the post files use the .html file extension. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
docs: enumerate the supported post formats in post metadata Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
docs: correctly describe the format of lisp metadata The leading quote requirement was removed from libjeffpc in 2016. Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>