Skip to content

Instantly share code, notes, and snippets.

View dermetfan's full-sized avatar

Robin Stumm dermetfan

View GitHub Profile
@Mic92
Mic92 / scrape-prs.py
Created October 22, 2023 05:57
Scrape all nixpkgs pull requests
#!/usr/bin/env python3
import http.client
import json
import os
import time
import urllib.parse
import urllib.request
from pathlib import Path
from typing import Any
@kimbtech
kimbtech / README.md
Last active September 3, 2022 13:13
Roundcube multiple SMTP Server plugin for setups having multiple IMAP Server.

This plugin is not needed for versions >= 1.5 of roundcube, as the functionality was added by the developers!

Roundcube allows to access multiple IMAP Server, but all mails have to be send over the same SMTP server. This plugin allows to add multiple SMTP Server (one per IMAP Server) to Roundcube.

// normal declaration of multiple IMAP Server
$config['default_host'] = array(
 'ssl://imap.example.de' => '.de',
@fnky
fnky / ANSI.md
Last active July 22, 2024 12:03
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@hyle
hyle / ko.utils.3.5.0.signatures.js
Created September 25, 2018 09:09
KnockoutJS 3.5.0 utils (ko.utils) signatures
// knockout 3.5.0
ko.utils.addOrRemoveItem = function (array, value, included) { /* .. */ }
ko.utils.anyDomNodeIsAttachedToDocument = function (nodes) { /* .. */ }
ko.utils.arrayFilter = function (array, predicate) { /* .. */ }
ko.utils.arrayFirst = function (array, predicate, predicateOwner) { /* .. */ }
{ config, lib, ... }:
with lib;
let
cfg = config.services.nixBinaryCacheCache;
nginxCfg = config.services.nginx;
@staltz
staltz / introrx.md
Last active July 22, 2024 09:31
The introduction to Reactive Programming you've been missing
@NathanSweet
NathanSweet / astar for libgdx
Last active March 27, 2024 13:12
A* for libgdx that is simple but optimized, includes runnable demo. Uses a binary heap for the open list. Nodes are cached in a PathNode[], which is also used to make finding a node in the open list fast. A "run id" is used to avoid needing to clear the nodes for a new run.
// A* for libgdx that is simple but optimized.
package test;
import com.badlogic.gdx.ApplicationAdapter;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.backends.lwjgl.LwjglApplication;
import com.badlogic.gdx.graphics.Color;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.graphics.glutils.ShapeRenderer;