Skip to content

Instantly share code, notes, and snippets.

@thorhop
thorhop / ffmpeg-update.sh
Created October 4, 2021 11:30
ffmpeg-update (as bundled with Vivaldi)
#!/bin/sh -eu
FFMPEG_VERSION_DEB='93.0.4577.63-0ubuntu0.18.04.1'
available () {
command -v "$1" >/dev/null 2>&1
}
available ldd && LIBC_MINOR_VERSION="$(ldd --version | head -n1 | sed -n '/^ldd .* [2-9]\./s/.*\.\([0-9]\+\)$/\1/p')"
LIBC_MINOR_VERSION="${LIBC_MINOR_VERSION:-27}"
@thorhop
thorhop / journalctl -f
Created May 10, 2020 15:51
pop-shell spamming me damn journal
May 10 17:51:08 pop-os gnome-shell[2702]: pop-shell: [DEBUG] unblocking signals for 3,0
May 10 17:51:08 pop-os gnome-shell[2702]: ../../../gobject/gsignal.c:2696: handler '63963' of instance '0x56017cd0fc70' is not blocked
May 10 17:51:08 pop-os gnome-shell[2702]: ../../../gobject/gsignal.c:2696: handler '63964' of instance '0x56017cd0fc70' is not blocked
May 10 17:51:08 pop-os gnome-shell[2702]: ../../../gobject/gsignal.c:2696: handler '63965' of instance '0x56017cd0fc70' is not blocked
May 10 17:51:08 pop-os gnome-shell[2702]: ../../../gobject/gsignal.c:2696: handler '63966' of instance '0x56017cd0fc70' is not blocked
May 10 17:51:08 pop-os gnome-shell[2702]: pop-shell: [INFO] focused Window(3,0) {
name: Tilix,
rect: Rect(0,27,1920,1053),
wm_class: "Tilix",
monitor: 0,
@thorhop
thorhop / main.rs
Created April 20, 2020 00:34
"The Book" (on Rust): Chapter 3.2 "Data Types".
// manual title: Data Types
// manual page: https://doc.rust-lang.org/book/ch03-02-data-types.html
fn numfail() {
// put anything else but u32 number in the variable
// and it will fail
let guess: u32 = "42".parse().expect("Needs to be a u32 number");
println!("Message: {}", guess);
}
@thorhop
thorhop / stdout
Created March 15, 2019 08:02
dbus-monitor brightness (ASUS ROG Zephyrus M GM501GM)
...
method call time=1552636809.781518 sender=:1.25 -> destination=:1.57 serial=1223 path=/org/gnome/SettingsDaemon/Power; interface=org.freedesktop.DBus.Properties; member=Set
string "org.gnome.SettingsDaemon.Power.Screen"
string "Brightness"
variant int32 31
method return time=1552636809.783493 sender=:1.57 -> destination=:1.25 serial=48 reply_serial=1223
signal time=1552636809.813330 sender=:1.57 -> destination=(null destination) serial=49 path=/org/gnome/SettingsDaemon/Power; interface=org.freedesktop.DBus.Properties; member=PropertiesChanged
string "org.gnome.SettingsDaemon.Power.Screen"
array [
dict entry(
@thorhop
thorhop / stdout
Created March 15, 2019 07:35
libinput record (ASUS Zephyrus M GM501GM)
...
Select the device event number: 11
Recording to 'stdout'.
version: 1
ndevices: 1
libinput:
version: "1.12.6"
git: "unknown"
system:
kernel: "5.0.0-7-generic"
@thorhop
thorhop / gimp-gmic-win10.log
Created January 29, 2018 13:50
G'Mic won't load on Windows 10 (gimp 2.8.22, gmic 2.1.9)
INIT: gimp_load_config
Parsing 'C:\Users\[redacted]\.gimp-2.8\unitrc'
Parsing 'C:\Program Files\GIMP 2\etc\gimp\2.0\gimprc'
Parsing 'C:\Users\[redacted]\.gimp-2.8\gimprc'
gimp_composite: verbose=no
Processor instruction sets: +mmx +sse +sse2 -3dnow -altivec -vis
Adding theme 'Default' (C:\Program Files\GIMP 2\share\gimp\2.0\themes\Default)
Adding theme 'Small' (C:\Program Files\GIMP 2\share\gimp\2.0\themes\Small)
Writing 'C:\Users\[redacted]\.gimp-2.8\themerc'
Trying splash 'C:\Users\[redacted]\.gimp-2.8\gimp-splash.png' ... failed
@thorhop
thorhop / ur44.log
Created May 4, 2015 14:35
sudo lsusb -d 0499:150e -vv
Bus 002 Device 050: ID 0499:150e Yamaha Corp.
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 255 Vendor Specific Class
bDeviceSubClass 0
bDeviceProtocol 255
bMaxPacketSize0 64
idVendor 0x0499 Yamaha Corp.
{
nixpkgs.config.packageOverrides = pkgs: rec {
libsigsegv = pkgs.stdenv.lib.overrideDerivation pkgs.libsigsegv (oldAttrs : { doCheck = false; });
kf5_stable = pkgs.kf5_latest;
plasma5_stable = pkgs.plasma5_latest;
kdeApps_stable = pkgs.kdeApps_latest;
};
}
@thorhop
thorhop / build.log
Created February 15, 2015 14:55
nixos-rebuild -I nixpkgs=~/Projects/Git/nixpkgs rebuild
building check-am
make check-TESTS
checking whether mkfifo is declared without a macro... make[2]: Entering directory `/tmp/nix-build-libsigsegv-2.10.drv-0/libsigsegv-2.10/tests'
building check-TESTS
Test passed.
PASS: sigsegv1
Test passed.
PASS: sigsegv2
Doing SIGSEGV pass 1.
Stack overflow 1 caught.
@thorhop
thorhop / default.nix
Created February 14, 2015 13:09
PlayOnLinux derivation
{ stdenv, python27Packages, makeDesktopItem, fetchurl, mesa, which, curl, xterm
imagemagick, cabextract, icoutils }:
let
py = python27Packages;
version = "4.2.5";
in
stdenv.mkDerivation rec {
name = "playonlinux-${version}";
src = fetchurl {