Skip to content

Instantly share code, notes, and snippets.

Avatar
🤔
Thinking…

rugk rugk

🤔
Thinking…
View GitHub Profile
@rugk
rugk / Notrufnummern.vcf
Last active Mar 28, 2020
Deutsche Notrufnummern
View Notrufnummern.vcf
BEGIN:VCARD
VERSION:3.0
PRODID:-//Sabre//Sabre VObject 4.1.6//EN
UID:fdd8f2e8-d55c-4e90-8b30-d75e95d1d4cc
FN:Telefonseelsorge
N:;Telefonseelsorge;;;
NEXTCLOUD1.TEL;TYPE=home:+49800111 0 111
NEXTCLOUD2.TEL;TYPE=cell:+49800111 0 222
NEXTCLOUD3.TEL;TYPE=cell:+49116 123
REV;VALUE=DATE-AND-OR-TIME:20200318T210456Z
View attackRedirect.html
<html>
<head>
<script>
// get when tab is switched
(function() {
var hidden = "hidden";
// Standards:
if (hidden in document)
document.addEventListener("visibilitychange", onchange);
View emojicoun.md
Country Users % of Total
Germany 1700 31.1%
United States 613 11.2%
France 427 7.8%
United Kingdom 303 5.5%
Italy 227 4.2%
Australia 134 2.5%
Poland 129 2.4%
@rugk
rugk / playground.ftl
Last active Jan 19, 2019
OSM "level" translation in fluent with alternative versions when travelling in foreign countries
View playground.ftl
### input data: ground floor = level 0
### for OSM "level" tag, see https://wiki.openstreetmap.org/wiki/Key:level
### KNOWN BUGS:
### 1. I cannot remove the minus (-) sign from negative levels. See https://github.com/projectfluent/fluent/issues/228
### 2. I cannot properly calculate +1 for the US style. See https://github.com/projectfluent/fluent/issues/227
## SYNTAX: floor_<userlanguage>_<country-travelling-to>
## i.e. e.g. floor_DE_EUROP = German-speaking user travelling to Germany (or any other country with basement=level 0)
@rugk
rugk / playground.ftl
Created Jan 19, 2019
OSM "level" translation in fluent
View playground.ftl
### input data: ground floor = level 0
### for OSM "level" tag, see https://wiki.openstreetmap.org/wiki/Key:level
### KNOWN BUGS:
### 1. I cannot remove the minus (-) sign from negative levels. See https://github.com/projectfluent/fluent/issues/228
### 2. I cannot properly calculate +1 for the US style. See https://github.com/projectfluent/fluent/issues/227
## Style, where floor = level 0 = input data
@rugk
rugk / instructions.md
Created Jan 1, 2019
old manual notification zenity proxy method for borbbackup-cron-helper
View instructions.md
  1. In the borg script you need to set, at least:

    # variable from user where notification should be shown, is usually static
    DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus

    If it does not work, you may need to set export DISPLAY=:0.

  2. In some cases (e.g. when using Wayland) you may additionally need to allow the user to access your Xorg server. Note that only root should be allowed to do that or a user, who is really only running borg. As the user where the notification should be shown execute: xhost +SI:localuser:<user running borg> This has to be done at each login, as the setting does not persist.

@rugk
rugk / revealjs-custom-navigation.js
Last active Jun 16, 2018
RevealJS – manually specify order/way to move through slides
View revealjs-custom-navigation.js
var customSlideOrder = (function () {
var me = {};
let cycleMode = null;
function customNavigate(navigate) {
const pos = Reveal.getIndices();
// use if's so keywords like "rightdown" are allowed
if (navigate.includes("right")) {
pos.h += 1
@rugk
rugk / 95-latinimegoogle.sh
Created Dec 21, 2017
OTA survival script for AOSP keyboard swipe (LatinME)
View 95-latinimegoogle.sh
#!/sbin/sh
#
# /system/addon.d/95-latinimegoogle.sh
# During an OS upgrade, this script backs up /system/lib/libjni_latinimegoogle.so,
# /system is formatted and reinstalled, then the file is restored.
#
. /tmp/backuptool.functions
list_files() {
@rugk
rugk / git-signing-key-proof.txt
Created Oct 3, 2017
Proof that the git signing key belongs to the other key
View git-signing-key-proof.txt
The PGP key for signing git commits (ABA9 B8F6 F448 B07F D7EA 4A1A 05D4 0A63 6AFA B34D) belongs to me, rugk <at> posteo.de.
Here is a copy of the full key:
- -----BEGIN PGP PUBLIC KEY BLOCK-----
mQINBFfIWIwBEADiNf/o13G2RlKSSQH5sriR5ReRwZ6rbuZjisaJzmQ9KKu7o+a9
T7XE88EwcyX3jwTH+mspvtjHNn4eyZHUYm3NmNI/8ZcsGMss6xMq7/27KvhYHvT8
uI+Y3Aszj3OZ1r/bne+D0lW+eY5obH+AR4wMnxLd9AggaQVDOCJ90S0lQJR3gc15
Sn6OdUZdTFc4VyxhsnJu0G/xGTTsxLO4ciBqUYbqDhaiFMNRijjiw601lxri/Cdu
@rugk
rugk / keybase.md
Created Oct 3, 2017
Keybase verification
View keybase.md

Keybase proof

I hereby claim:

  • I am rugk on github.
  • I am rugk (https://keybase.io/rugk) on keybase.
  • I have a public key whose fingerprint is 7046 C1B2 8644 9EAF 9F3F F5C1 8F16 2AE4 4088 F1BE

To claim this, I am signing this object: