Sekai ๐ŸŒ ๐Ÿ—บ

Sekai (ไธ–็•Œ) is the kanji for “the world”. That’s a great word because of the scale that it designates.

Staticman Script in Pure JS

Staticman without jQuery

The official Staticman script sample depends on jQuery. I have been using jQuery in my Staticman script for nested comments for more than six months. Recently, in the new release of Hugo Swift Theme, in which I’m a collaborator, one has removed all jQuery methods at commit f137efa4. Here’s the structure of the script: auxiliary functions like elem, elems, pushClass, deleteClass, etc. A self-executing function comments() some necessary local variables handleForm() consisting merely of an event listener handling form submission. [Read More]

Staticman With Introduction Theme

Goal To port Huginn’s Staticman integration to Introduction. Difficulties I’ve used some class names from Minimal Mistakes since the modals in the original code clashes with Introduction’s mobile responsive card display for projects. If I had know the practice of prepending a CSS class to avoid overiding the CSS properties of other components of a web site, I wouldn’t have mixed this Jekyll theme with my template for nested comments. [Read More]

CPU Temperature Display in Conky

Background I’m using Conky for monitoring the system. After a system upgrade, the CPU temperatures were gone. Conky’s standard error showed the following. Conky: can't open '/sys/class/hwmon/hwmon0/temp3_input': No such file or directory please check your device or remove this var from Conky... Source of message: https://bbs.archlinux.org/viewtopic.php?id=82231 An easy fix would be to adjust the following lines in .conkyrc according to the number N in /sys/class/hwmon/hwmonN containing the file temp3_input. (You may adjust the number 3 according to the number of CPU of your device. [Read More]
Conky  CPU  Linux 

Animated GIF Screenshots on Ubuntu

Background I’ve to take screenshots to demonstrate Conky’s visual output. I’ve chosen Byzanz after reading this answer on Ask Ubuntu. Peek is more user-friendly, but I prefer CLI’s precision. That’s feasible thanks to a comment mentioning xwininfo. After typing xwininfo, click on the target window. Switching to adjacent workplace is possible. $ xwininfo xwininfo: Please select the window about which you would like information by clicking the mouse in that window. [Read More]

More Static Nested Comments

Background I’ve made nested comment support for Beautiful Hugo, which I’ve ported to other Hugo themes like Introduction, Hyde-hyde, etc. Problem I Some of those Hugo themes that I worked with did show the HTML form, but the CSS styles were gone on the GitLab Pages. Reason I This is due to the lack of resources/_gen/ in the indexed repo for themes making use of assets/. Solution I Check that you have the required prerequisites. [Read More]

Huginn Theme With Staticman

Goal To provide Staticman support to the Hugo theme Huginn. Motivation A Framagit user tried using the public GitLab instance but failed. Finally, he removed Staticman from his site and his Hugo theme. If I had been notified, I would have explained that that was due to the constraint of gitlabBaseUrl, which could only take one GitLab instance. In response to demand for Staticman from Framagit users, I set up another GitLab instance of Staticman API and forked some Hugo/Jekyll repo under the project page Staticman et GitLab Pages. [Read More]

Right PATH to Linux

Roles of various config files

Background Updated $\LaTeX$ version From this $\TeX$-SE question about tlmgr, we see some advantages of installing $\TeX$Live directly from the official site: avoid errors due to outdated version of $\TeX$Live supplied by the OS’s package manager easier to manage packages with tlmgr. enjoy the newer version of $\TeX$Live not yet available in your current GNU/Linux version. The installation took about 30 minutes and 5G in the disk. I’ve chosen a local installation as this didn’t require sudo privileges. [Read More]
Linux 

Package Versioning for Julia Projects

Resolved GLM installation error

Update: Thanks to JuliaRegistries/General#647, the version cap of the package Distributions has now been removed, so that one can directly install the package GLM along with Distributions v0.19.2. Background I’m reading the book Statistics with Julia, which makes use of GLM. Problem I encountered the following error, which I posted in the issue GLM.jl#311. (v1.1) pkg> add GLM Resolving package versions... ERROR: Unsatisfiable requirements detected for package GLM [38e38edf]: GLM [38e38edf] log: โ”œโ”€possible versions are: [0. [Read More]
Julia  GLM 

Insensitive Laptop Touchpad

Log of my Ubuntu Tweak config

Problem The touchpad on my new Ubuntu 18.04 LTS laptop was frozen. Toogling ๐Ÿ–ฑ with <Fn>-<F4> didn’t worked. Attempt Logout: didn’t work at all Reboot: worked most of the time Partial solution After changing the Mouse Click Emulation in Keyboard & Mouse in Ubuntu Tweak from the default “Fingers” (2 fingers for right click; 3 fingers for middle click) to “Area” (Right/middle click determined by clicked area), one might have to wait for next reboot. [Read More]

Juno Installation 2019

Log of system-wide config

Goal To install Juno for convenient development in Julia. Problem After Juno installation, I received the following error. Analysis From the error message, the system had tried to find an executable file julia, which would then be executed by the shell /bin/sh. Nonetheless, it’s absent from the system’s environment $PATH, so Juno couldn’t find it. I’ve only changed my $PATH in ZSHRC, which is user-specific. Solution This Stack Overflow question about $PATH setting on *nix has provided various solution. [Read More]
Juno  Atom  Julia