MN/About

Information about me and this site.

About me

I’m called Matti Niemenmaa, and am also known as Deewiant in some online circles. I’m male, about a score of years old, and live in Finland.

I’m a candidate student (equivalent to bachelor’s, as far as I can tell from my limited understanding of the various university systems) at TKK, with the plans to complete a major in maths and a minor in computer science, though that may yet change. I am also enrolled at HSE, where I intend to study finance, but that may also change.

I dabble a lot in programming, which is reflected in the content of this site.

Contact information

The surest way to contact me is with e-mail: use the address (my forename).(my surname)+web at the domain iki.fi. If you feel the need for encryption, use my GPG public key.

I can occasionally be found on IRC (Wikipedia article) with the nickname Deewiant.

About this site

This is my personal web site, and holds content which is mostly, if not entirely, by me. Topics vary, though currently the only content-worthy stuff I’ve made relates to one of my primary interests, programming.

This site should always be accessible at http://www.iki.fi/matti.niemenmaa/ or http://www.iki.fi/deewiant/. Please don’t use any other URLs to link to this site: they may be invalidated at any moment, causing needless confusion and annoyance.

Technical details

The site content is written in Pandoc, a variant of Markdown, with a little HTML (Wikipedia article) thrown in wherever Pandoc is too limited.

Styling is done with CSS (Wikipedia article), as is the norm these days. I use some things defined only in version 3, though.

All editing is done with Vim.

The site is hosted at TKK and not my own server, which limits me in the following ways:

This means that:

This, in turn, means that I have a somewhat interesting model of making my pages:

  1. I write a page in Pandoc, possibly also moving related files to the downloads directory.

  2. I run an Adjutant which does all of the following for every Pandoc file in the source directory (for others, it merely copies it to the built directory):

    1. Runs a Perl script on the file, which inserts a common header at the start of the file and a footer at the end of the file. Also, a middle part which I call header_post (the previous header was header_pre) is inserted as soon as the text body begins.

      The header_pre contains such stuff as a DOCTYPE (Wikipedia article) and the beginning of the contents of the HTML <head> element.

      header_post ends the <head> element (thus, pages may insert things into the element as long as it’s prior to any line beginning with #) and starts the <body> element, creating the top-level page header.

      footer includes the navigation and the closing page tags.

      The output of the above is redirected to the built directory, where the rest of the processing continues.

    2. Runs PHP on the file. PHP isn’t used for much: some requires, generating the page title (so that the sub-page prefix is specified only in one place), and the permalinks on each page.

    3. Runs Pandoc on the file.

    4. Runs a script using Beautiful Soup on the file. The script fixes absolute links by taking any href or src attribute whose value starts with / and replacing that slash with the subdirectory my site is in.

      This means that I can write my source as though the root directory of my site were /, though it’s not.

      A bonus of Beautiful Soup is that it converts HTML entities to Unicode code points.

      I use a customized version of Beautiful Soup version 3.0.5, which:

      • Doesn’t insert / in self-closing HTML tags.
      • Doesn’t convert &lt; to <, or &amp; to &.
      • Is aware of the <col> tag.
      • Uses &#39; instead of &squot;.
      • Doesn’t replace the contents of tags containing only tabs with spaces.

      The customization is necessary to prevent it from mangling the output: in many cases the unmodified version would make the resulting HTML invalid.

    CSS files are processed a bit as well:

    1. They are also run through PHP, so that I can use variables in them. Whilst PHP’s syntax is ugly for this purpose, it’s usable.

    2. They are run through CSSTidy to optimize them, in a similar (but far more effective) way as the sed on the HTML.

    There are so many HTML and CSS pretty printers that I think it’s best to just write standards-conforming HTML and CSS, compress it as much as possible for speedy viewing, and let users use said pretty printers to view it, if they so wish.

  3. I use rsync over SSH (Wikipedia article) to upload the contents of the built directory to the school’s server.

The end result is what you have here.

Web buttons

Because every personal web site needs to profess its conformance to a standard or sixteen.

Valid HTML 4.01 Strict Valid CSS Viewable with any browser Created with Vim

Navigation:

Please use this permalink when linking to this page.

This page is part of the personal web site of Matti Niemenmaa (contact).