Skip to content

Instantly share code, notes, and snippets.

View Luzifer's full-sized avatar

Knut Ahlers Luzifer

View GitHub Profile
@Luzifer
Luzifer / README.md
Last active March 4, 2020 22:36
Automatic update processing on Archlinux with options for unattended upgrades
@Luzifer
Luzifer / gcr-clean.sh
Last active February 24, 2023 19:48
Cleanup script for untagged revisions in GCR repos
#!/bin/bash
set -euo pipefail
: ${DELETE_OLDER_THAN:=0} # When to delete tags by time (days)
: ${PROJECT:=${1:-}} # Which project to clean
COLOR_RED="\033[0;31m"
COLOR_GREEN="\033[0;32m"
COLOR_CYAN="\033[0;36m"
COLOR_YELLOW="\033[0;33m"
@Luzifer
Luzifer / README.md
Last active November 23, 2019 19:17
Generate an user.js configuration for Firefox to have it less talkative

Luzifer / firefox-config

This repo contains an approach to create a reproducible configuration (as far as possible) for Firefox on my Linux system.

Usage

  • Put mkuserjs.sh into your ~/.mozilla/firefox/<profile id> folder
  • Create your own user_js_customize.sh file next to it
  • Execute the mkuserjs.sh file: bash mkuserjs.sh
  • Review the diff and decide whether to write or to discard the change
@Luzifer
Luzifer / free-replug.user.js
Created October 6, 2019 12:07
Break framed websites free from their replug.io framing
// ==UserScript==
// @name Free sites from replug.io
// @namespace https://luzifer.io/
// @version 0.1.1
// @description Break framed websites free from their replug.io framing
// @author Knut Ahlers
// @match https://rplg.co/*
// @grant none
// ==/UserScript==
@Luzifer
Luzifer / PKGBUILD
Last active December 14, 2018 15:45
Binary package as alternative to deprecated community/consul - https://www.archlinux.org/packages/community/x86_64/consul/
pkgname=consul-bin
pkgver=1.4.0
pkgrel=1
pkgdesc="A tool for service discovery, monitoring and configuration."
arch=('x86_64')
url="https://www.consul.io"
license=('MPL2')
depends=('glibc')
conflicts=('consul')
source=("${pkgname}-${pkgver}.zip::https://releases.hashicorp.com/consul/${pkgver}/consul_${pkgver}_linux_amd64.zip"
@Luzifer
Luzifer / .SRCINFO
Last active December 2, 2018 23:32
pkgbase = getxkblayout
pkgdesc = Simple CLI command to read current active KB map from X server
pkgver = 0.0.1
pkgrel = 1
url = https://gist.github.com/Luzifer/dccae45747a1dad41f011a01c75296a3
arch = x86_64
license = Apache
makedepends = gcc
makedepends = libx11
makedepends = libxkbfile
@Luzifer
Luzifer / google-chrome-ver.py
Created November 25, 2018 12:39
GCP Cloud-Function (PY3.7) to retrieve current Google Chrome version from official repo data
import flask
import gzip
import json
import requests
import sys
import xml.etree.ElementTree as ET
REPO_URL = "https://dl.google.com/linux/chrome/rpm/stable/x86_64/repodata/other.xml.gz"
@Luzifer
Luzifer / 00-touchpad.conf
Last active January 9, 2023 07:44
MacBook xorg Config
Section "InputClass"
Identifier "Touchpads"
Driver "mtrack"
MatchIsTouchpad "on"
Option "TrackpadDisable" "0" # Disables trackpad touch input. A value of 1 will enable the trackpad.
# A value of 1 will disable tapping and gestures but not movement. A value
# of 2 will disable all input. A value of 3 will also disable physical
# buttons. Integer. Default is 0.
@Luzifer
Luzifer / aur-packages.txt
Last active May 7, 2023 15:26
Arch Linux Package List
We couldn’t find that file to show.
@Luzifer
Luzifer / go-licenses.sh
Last active August 6, 2018 11:54
Shell script to list licenses of Go dependencies through the Github license API
#!/bin/bash
set -euo pipefail
# Export GITHUB_TOKEN shell variable with a Github token with no special
# permissions assigned. Afterwards start the script with a import path
# prefix as first argument:
#
# go-licenses.sh github.com/Luzifer
replaces=(