==========
== 0x2f ==
==========

It sucks to be a forgetful citizen

Here I am, “citizen”, the person that’s supposed to keep the government in check.

But I am so forgetful. If a politician does something stupid and it’ shown on TV - and they do so many stupid things - there’s so much things to remember. So much, that the next day I unconciously forget about the whole thing.

My own forgetfulness was painful to me especially during the two govt. terms before 2023 in Poland. I know for a fact that there were criminal things happening. Just that … I can’t list them - I don’t remember them anymore. But they certainly deserved to be remembered, especially by a good citizen.

Read more...

"gio open" opening file in a different program than "gio mime [mimetypehere]" suggests

x-scheme-handler/file=emacs.desktop overrode everything.

The problem

Dino, my chat program, opens .webm in Emacs instead of MPV.

The diagnostics

Per https://github.com/dino/dino/issues/916#issuecomment-1006535011 looks like Dino uses the https://valadoc.org/gio-2.0/GLib.AppInfo.launch_default_for_uri.html method.

I think this means that I need to use gio instead of xdg-open when diagnosing any issues like this.

Anyways, I downloaded a sample file (webm) and saved it as test.webm

file test.webm --mime returned video/webm; charset=binary

gio mime video/webm returned

rt@hp400 /home/rt $ gio mime video/webm

Default application for “video/webm”: mpv.desktop
Registered applications:
    mpv.desktop
Recommended applications:
    mpv.desktop

So if I run gio open test.webm, it should open in MPV right?

Read more...

Can't /ssh: into TrueNas SCALE root user with Emacs TRAMP

This is happening because TrueNAS’s root user runs a .zshrc file where PROMPT= is set to something that TRAMP doesn’t understand. While in an SSH session as root on the TrueNAS machine, make sure that you’re running zsh using echo $0, then open the file /root/.zshrc, comment out PROMPT​="%n@%m[%40<...<%~%<<]# " (fourth line from the top), save, and try connecting with TRAMP again.

Can't paste screenshots on IceCat browser

Whenever I screenshotted a region of my screen and put the image data into the clipboard, I noticed that I can’t paste the screenshot into my Mastodon posts. The culprit turned out to be the dom.events.clipboardevents.enabled Firefox pref in about:config. Make sure to set it to true and it’ll start working.

Running language servers and linter using Bun instead of Node

Bun is a new JavaScript runtime claiming to be faster. Would it help if we used it to run tooling we’d like to see running faster - ESLint, language servers?

Primer: How NPM runs packages

Remember that whenever you run npx eslint, npm goes to ./node_modules/.bin/eslint and runs it as if it were a regular program. It will respect the shebang at the top of the file. The files inside .bin/ don’t even need to be JavaScript files. It could be a shell script and as long as there’s a proper #!/bin/bash shebang at the top, NPM would run it anyway.

Read more...

Running the TrueCharts Baikal chart from Incubator

EDIT: This is better now

Thanks to changes made in https://github.com/ckulka/baikal-docker/issues/134 it’s now possible to set BAIKAL_SKIP_CHOWN=true env var through the TrueNAS “Extra Environment Variables” field. This removes the need for making a bind mount as described later in this post.

Fingers crossed for enabling this by default in the TrueCharts image: https://github.com/truecharts/charts/issues/16573

Why is this happening

It doesn’t work out of the box. You need to make a bind mount that removes one file from within the image. When trying to run the Baikal TrueCharts chart, you’ll find that the app will be stuck in the “Deploying” state. The Docker image that this chart uses (baikal-docker:nginx) works like this:

Read more...

Which Anki sync server should I pick?

EDIT: Some more organizational info here https://github.com/ankicommunity/.github/issues/1

There are many repos containing Anki sync server implementations:

Which one should I use?

None of the ones listed above.

It’s hard to see (because only one of the above repos mentions it, would be nice if those repos were archived), but the sync server implementations were moved to the core repo https://github.com/ankitects/anki

Read more...

Mopidy as Mumble music bot

Botamusique re-implements many media player features - web interface, playing music from youtube.
However, there are traditional FOSS media servers out there implementing the same features, like Mopidy.
In this post, I’ll show you how to make Mopidy do all the media-related heavy lifting, and how to only redirect the audio from Mopidy so you can hear it in a Mumble server.

Why Mopidy

I understand you may already have e.g. Navidrome or Jellyfin on your local network and may be annoyed by having to install “yet another” media server.

Read more...

How to: apex domain, with HTTPS, in Azure CDN

Get ready for pain.

I assume you’ve already done this:

  1. Created a static blog from an Azure Storage account
  2. Hooked up Azure CDN to it.
  3. Tried to enable a managed HTTPS cert for a custom domain that happens to be a naked/apex domain - eg. “0x2f.pl” instead of “www.0x2f.pl

Since Azure won’t generate this for you, YOU WILL HAVE TO set up additional Azure resources to automate generating the cert for you. To bring you some relief - somebody already made an Azure blueprint for this.

Read more...

Music bots for your Mumble voice chat server

Say you have a Mumble server, but you’d like to play audio from youtube videos in the background while talking to your friends. Discord users may be used to using Rhythm for that purpose. This experience can be replicated in Mumble as well.

The most complete list of bots can be found on Mumble wiki’s “3rd Party Applications” page, where you’ll find the likes of botamusique, JJMumbleBot etc. Up until now, I’ve used botamusique, so this is the bot I’m going to talk about further on.

Read more...
Previous Page 2 of 3 Next Page