Skip to content

Instantly share code, notes, and snippets.

@adelton
adelton / git-submodule-reset.sh
Last active January 22, 2026 06:55
git submodule reset
git submodule foreach --recursive git reset --hard ; git submodule update --init --recursive

AlmaLinux-9-OCI-9.5-20250205.aarch64

[opc@test-ipv6-almalinux ~]$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
$ podman run --rm -ti registry.fedoraproject.org/fedora-minimal:41
bash-5.2# dnf install -y asciidoc bash binutils bzip2 flex git-core gcc-c++ gcc util-linux gawk gzip help2man intltool elfutils-libelf-devel zlib-devel make ncurses-devel openssl-devel patch perl-ExtUtils-MakeMaker perl-Thread-Queue swig unzip wget gettext libxslt zlib-devel zlib-static which rsync perl-FindBin perl-IPC-Cmd tar perl-Time-Piece
bash-5.2# dnf install -y tar zstd
bash-5.2# curl -O https://downloads.openwrt.org/releases/24.10.0-rc5/targets/x86/64/openwrt-sdk-24.10.0-rc5-x86-64_gcc-13.3.0_musl.Linux-x86_64.tar.zst
bash-5.2# tar xvaf openwrt-sdk-24.10.0-rc5-x86-64_gcc-13.3.0_musl.Linux-x86_64.tar.zst
bash-5.2# cd openwrt-sdk-24.10.0-rc5-x86-64_gcc-13.3.0_musl.Linux-x86_64
bash-5.2# vi feeds.conf.default
@adelton
adelton / bugzilla-favicon.js
Last active March 28, 2023 23:39
Violentmonkey scripts
// ==UserScript==
// @name Set bugzilla favicon
// @namespace Adelton Violentmonkey Scripts
// @include https://bugzilla.redhat.com/*
// @grant none
// ==/UserScript==
var link = document.querySelector("link[rel = 'shortcut icon']");
if (!link) {
link = document.createElement('link');
@adelton
adelton / google-calendar-color-undecided.tampermonkey
Created March 1, 2018 07:09
Google Calendar color undecided items
// ==UserScript==
// @name Google Calendar color undecided items
// @namespace adelton
// @description New 2018 Google Calendar, color undecided items to make clearer which calendar they are in
// @include https://www.google.com/calendar/*
// @include https://calendar.google.com/*
// @version 1.1
// @grant none
// ==/UserScript==
document.addEventListener('DOMNodeInserted', function() {
@adelton
adelton / google-calendar-color-items.tampermonkey
Last active February 27, 2018 09:04
Google Calendar color tasks, not dots
// ==UserScript==
// @name Google Calendar color tasks, not dots
// @namespace adelton
// @description New 2018 Google Calendar, color the tasks instead of the colored dots
// @include https://www.google.com/calendar/*
// @include https://calendar.google.com/*
// @version 1.1
// @grant none
// ==/UserScript==
document.addEventListener('DOMNodeInserted', function() {
In projects where I only participate in some small areas, I often want to fetch
or update just one (or few) particular pull request, without polluting my repo with the full
fetch = +refs/pull/*/head:refs/pull/origin/*
configuration. To do that, one-off command like
git fetch origin refs/pull/529/head:pr-529 -f
does the trick.