Repository navigation
Accent CMS v0.27.2
A bug-fix release for the v0.27 line that also carries two features. It
fixes six bugs: accent.exe failed to start on a Windows install without
the Visual C++ runtime, components linked with a doubled prefix on a
sub-path deployment, accent build --base-url reached only the sitemap,
tabs did not switch on a site from accent init, a ---section: region
skipped most of the body's markdown stages, and a markdown-only site failed
its own link check. With markdown-only output, every page is now markdown,
the generated host configuration serves it, and the link check reads it.
Taxonomy terms keep the spelling authors write, and pages carry
page.taxonomies.
Cut from the release/0.27.x maintenance branch rather than from master,
so anyone whose licence ceiling is 0.27 can take it.
Changed
What templates see changes in these places:
- Each term in
taxonomy.tagsand in a configured taxonomy's
taxonomy.<name>has alabel, and a term page has
taxonomy.current_label. A term page's title uses the label:
Tag: Beratung aarewhere it wasTag: beratung aare. page.taxonomiesholds the page's configured taxonomies' terms as lists.page.toclists a---section:region's headings after the body's.- With
accent build --base-url,site.urlis the flag's URL, and so is
every absolute URL derived from it. - In a component,
url(),media(),page.urlandall_pagesURLs are
root-relative; Accent adds the deployment prefix once when it places the
component. - With markdown-only output, tag and category pages and the 404 page render
through.md.jinjatemplates:tags.md.jinja,tag.md.jinja,
error/404.md.jinja, and a taxonomy's own twins.
Added
-
Every page of a markdown-only site is markdown. With
content.markdown_view.default_format: markdown, tag and category pages
and the 404 page are now markdown too, inaccent serveand
accent build, sent astext/markdown; charset=utf-8. Each renders
through the.md.jinjatwin of its HTML template --tags.md.jinja,
tag.md.jinja,error/404.md.jinja-- and, when the theme has none,
through a built-in markdown list or message. The build writes them as
tags.md,tags/cli.mdand404.md, and the default theme ships the
templates.accent serve-staticanswers a missing page with404.md. -
The generated host configuration serves markdown-only output. With
build.header_artifacts, the.htaccessand the Netlify_redirects
and_headersnow answer each page's URL from its.mdfile,/from
index.mdand a missing page with404.md, send.mdfiles as
text/markdown; charset=utf-8, and answer the build's redirects with a
redirect status, which an HTTP client follows. The static build guide
states the rule a host needs and gives tested Caddy and nginx
configurations. -
Taxonomy terms keep the spelling authors write. Each entry of
taxonomy.tagsand of a configured taxonomy'staxonomy.<name>has a
label: the term as the first page in URL order writes it, such as
Beratung aarefor the nameberatung aare, and on a site with several
languages, as that language's pages write it. Printlabeland compare
nameorslug. On a term page,taxonomy.current_labelis the term's
label, and the page title uses it:Tag: Beratung aarewhere it was
Tag: beratung aare. The shipped tag and category pages print it. -
page.taxonomiesgives the page being rendered its configured
taxonomies' terms as lists, asp.taxonomiesdoes for a listing entry:
categories: praxisandcategories: [praxis]are both
page.taxonomies.categories. Read a taxonomy the page may not use as
page.taxonomies.categories | default([]).
Fixed
-
A markdown-only listing's later pages are markdown files. Page 2 of
a listing was written asblog/page/2/index.htmlwith markdown inside,
so a host sent it as HTML. It is nowblog/page/2.md, served at
/blog/page/2like any other page. -
The build checks the links in a markdown-only site's pages. The link
check read only.htmlfiles, so in markdown-only output it read no
page, and a link to a missing page shipped. It now reads each.md
page's links, skipping code, and a broken one fails the build. -
A markdown-only site builds without
--lax. With
content.markdown_view.default_format: markdown,accent buildwrites
each page as<url>.md, but its link check looked for
<url>/index.html, so every build failed on the redirect stubs it wrote
itself. The link check now resolves a page's URL to its.mdfile in this
mode, and the build no longer warns about a redirect at the page's own
.mdfile.accent serve-staticnow serves these pages at their URLs,
/fromindex.mdand/docs/guidefromdocs/guide.md, and the static
build guide shows how to configure Caddy to do the same. A "failed to
write file" error now names its cause. -
A
---section:region renders like the page's body. A section ran
only a few of the body's markdown stages, so its headings had noid,
anchor link orpage.tocentry, its code was not highlighted, its
> [!NOTE]admonitions rendered as plain blockquotes, and its diagram
fences stayed code blocks, inaccent buildandaccent serve. A section
now renders through the same stages as the body. Its headings join
page.tocafter the body's, in the order of the section names, so a
template that builds a table of contents frompage.tocnow lists them
too. A section heading that repeats a body heading's text gets the next
free id, such asoverview-1. Two consequences when you upgrade: with
diagrams.on_error: fail, a diagram that fails in a section now fails
accent build, as one in the body does; and under a frontmatter
rewrite,accent serveresolves a section's relative links against the
URL being served, as it does the body's and asaccent buildalready
did. -
Tabs switch on a site from
accent init. The starter theme declared
js/tabs.jsintheme.yamlbut its base template loaded no script, so
{% tabs %}showed the first panel and never switched, since 0.26.0. The
template now loads the theme's declared scripts. A site created from the
starter before this release keeps its own copy of the template: add these
lines before</body>inthemes/simple/templates/base.html.jinja:{% for js in theme.assets.js %} <script src="{{ url('/theme/assets/' ~ js) }}" nonce="{{ nonce }}"></script> {% endfor %}
-
accent build --base-urlsets every absolute URL. The flag reached the
sitemap androbots.txtonly: canonical links,og:url,absolute_url(),
JSON-LD and the feeds kept the host ofsite.urlin the config, and with a
different path they joined the old URL to the new path, a URL that existed
nowhere. The flag is now the build'ssite.url. Its path is the base path
unless--base-pathorsite.base_pathsets one, also when it has no
path:--base-url https://example.combuilds for the root even if the
config'ssite.urlhas a path, and the build says so. The flag must be an
http://orhttps://URL with no query or fragment. -
Components link correctly on a sub-path deployment. Since 0.27.0, the
button,card,imageandtagcomponents of every shipped theme,
and any component that wrote a URL fromurl(),media(),page.urlor
all_pages, put the deployment prefix in twice under a base path
(/site/site/blog), soaccent buildfailed its link check andaccent serverendered broken links. In a component, those URLs are now
root-relative, and Accent adds the prefix once when it places the
component in the page;site.base_pathandabsolute_url()keep the
prefix. The link check names a link with a doubled prefix as written.
Components in.mdoutput now write root-relative URLs, as the page's
own links there do. -
accent.exestarts on a clean Windows install. The Windows binaries
of every release from 0.22.0 to 0.27.1 neededVCRUNTIME140.dll, which
comes with the Visual C++ Redistributable rather than with Windows. On a
machine without it,accentfailed to start with a missing-DLL error (exit
code-1073741515), however it was installed; WinGet's validation failed
the same way. The C runtime is now linked intoaccent.exe, so it needs
only the DLLs Windows ships, and the release fails if a binary imports any
other. Ifaccentdid not start for you, install this release, or the
Visual C++ 2015-2022 Redistributable for an earlier one.
Verifying your download
curl -fsSLO https://raw.githubusercontent.com/AccentCMS/accent/main/release-signing-key.asc
gpg --import release-signing-key.asc
gpg --verify checksums-v0.27.2.txt.asc checksums-v0.27.2.txt
sha256sum -c --ignore-missing checksums-v0.27.2.txt