Day 139




    Bash dtb script

    Updated the script to create a markdown dtb file to the following:

    FILE=_posts/$(date +%Y-%m-%d)-day$(date +%j).markdown
    DATE=$(date +%Y-%m-%d\ %H:%M:%S\ +0100)
    if test -f "$FILE"; then
            vim $FILE
            exit 1
    echo "Creating file $FILE"
    touch $FILE
    echo "Adding stuff"
    /bin/cat <<EOM >> $FILE
    layout: post
    title:  "Day $(date +%j)"
    date:   $DATE
    categories: []
    vim $FILE

    Now it’s closer to and doesn’t overwrite anything if run again by error, doesn’t add any unused parts, and opens the file if it exists already.

    Bash check if file exists

    if test -f "$FILE"; then
            vim $FILE
            exit 1

    Bash exit script

    exit 1 or whatever status code.

    Bash suppress output of command (bash redirection)

    command > /dev/null 2>&1 redirects both stdout and stderr to /dev/null
    command &> /dev/null & works for me too, though it may not work in all shells. command > /dev/null still shows errors.

    Day 138: bspwm and some configs

    After another small pause, here comes another längliches post!

    Urxvt -name and settings

    I had been trying to get urxvt to play with i3 scratchpads, but when I set the -name setting I got a vanilla URxvt look.

    You evidently configured the font for a specific application instance rather than for an application class. (SO). To make your settings always apply, set URxvt.font rather than urxvt.font, etc.

    Solved my problem.

    Though at the end, I spent some time looking for a way to grep “name” instead of “class” for URxvt in bspwm and gave up, now typing this on a st terminal and loving every second of it!


    Is the terminal I might start to use everywhere.

    In config.h I changed the font to be static char *font = "DejaVu Sans Mono:pixelsize=12:antialias=true:autohint=true";


    Decided to give it a try, loving it!


    To implement the scratchbox, used the method described in the Arch wiki.

    In bspwmrc,

    t -c scratchterm &
    bspc rule -a scratchterm sticky=on state=floating hidden=on

    In sxhkdrc,

    super + minus

    In ~/s/scratch,

    #!/usr/bin/env bash
    id=$(xdotool search --class scratchterm | head -n 1)
    echo $id
    if [ "$id" != "" ]
           bspc node "$id" --flag hidden -f

    I added |head -n 1 so it can better deal with possible multiple terminals of this class, in case I have to restart bspwm for whatever reason.


    • The hype cycle of working memory training
      • near transfer is much more likely and proven than far transfer
      • in general doesn’t look to optimistic
      • High IQ/WM people benefit the most
      • High spacing seems the best for transfer
        • might be related to all those other “pauses are good you learning” effects
    • Spectrometer using a CD
    • ‘I’ve become very isolated’: the aftermath of near-doomed QF72
      • Like a bad partner, the computer’s systems went crazy then stopped communicating with me.

      • I’ve become very isolated. When you’ve been to the Moon, you can only talk to astronauts.

    • The Copenhagen interpretation of ethics
      • Excellent.
      • The Copenhagen Interpretation of Ethics says that when you observe or interact with a problem in any way, you can be blamed for it. At the very least, you are to blame for not doing more.

      • The program was helping as many people as it could, the only change was explicitly labeling a number of people it wasn’t helping as a “control group”. The response?
        “They should immediately stop this experiment, ” said the Manhattan borough president, Scott M. Stringer. “The city shouldn’t be making guinea pigs out of its most vulnerable.”

    Arch compiling AURs from source

    Didn’t have to do this a long time:

    1. makepkg -Acs
    2. sudo pacman -U x.pkg.tar.xz

    Day 133


    • Formalize my Sprint reviews.
    • Three works a week of PI – how do I actually keep track of this? I need an infrastructure.


    Block-level attributes in Jekyll/kramdown/markdown

    This describes amongth other things block-level stuff for Markdown. This is potentially a solution for different footnotes and various other small design tweak I’d like to have on this blog. I can just add a CSS class and then in CSS see what I want to do with it.

    Git diff a file between revisions

    git diff HEAD^^ HEAD – where HEAD^^ is “two revisions back”. Also the option --compact-summary gives number of insertions and deletions.

    Anki steps

    It’s an interesting thing to research someday. This discussion and similar ones can be a reference, along with looking at the graphs and targeting 80% retention.

    In general I really should invest an hour or so to learn everything about Anki, so far it’s been the single most effective tool I have for my memory but am using it on a default and primitive level.

    For now I changed Steps to “1 10 60” and “10 60”, new interval to 30%.

    To print for The Road

      • till page 123 or so

    Day 131


    • Remember that Eisenhower Matrix is a thing and that it used to help me quite a lot before.
    • I should formalize all the checklists I created for myself and use them.
    • Look into Energy Management vs Time management
      • etc.

    Day 127


    Chrony would solve most of my NTP problems.


    Day 126


    Day 124

    Swagger API documentation



    Day 123