Skip to content

Instantly share code, notes, and snippets.

@scottsb
scottsb / resetting-csync2-cluster.md
Last active October 25, 2021 20:28
Guide to Resetting a csync2 Cluster

Guide to Resetting a csync2 Cluster

Introduction

These are possible steps to reset a csync2 cluster that has been seriously fubared. This is an apocalyptic approach and should only be used when more surgical fixes (like correcting an individual conflict) aren't workable.

Use Cases

@dfletcher
dfletcher / tsws
Last active July 21, 2018 12:47
Totally simple web server using Bash and netcat (nc)
Moved to a proprer repositoy, TSWS is a real boy now!
https://github.com/dfletcher/tsws
PRs welcomed.
@derhuerst
derhuerst / _.md
Last active February 17, 2026 12:37
List of HAFAS API Endpoints
@paulirish
paulirish / bling.js
Last active February 27, 2026 04:33
bling dot js
/* bling.js */
window.$ = document.querySelector.bind(document);
window.$$ = document.querySelectorAll.bind(document);
Node.prototype.on = window.on = function(name, fn) { this.addEventListener(name, fn); };
NodeList.prototype.__proto__ = Array.prototype;
NodeList.prototype.on = function(name, fn) { this.forEach((elem) => elem.on(name, fn)); };
@moschlar
moschlar / README.md
Last active March 25, 2019 05:01
Build and install ShareLaTeX in Ubuntu 14.04 LTS

Since the official ShareLaTeX documentation is primarily written with Ubuntu 12.04 LTS in mind, I tried to re-build the provided .deb from scratch using Ubuntu 14.04 TLS with the least amount of non-standard or non-packaged software.

Here are all the steps that were required (with sudo since Ubuntu doesn't want you to be root).

First, install lots of packages - note that no additional repositories are required! (Dependencies):

$ sudo apt-get update
$ sudo apt-get install git build-essential curl python-software-properties zlib1g-dev zip unzip
$ sudo apt-get install ruby-dev
$ sudo apt-get install nodejs npm
@grugq
grugq / gist:03167bed45e774551155
Last active February 1, 2026 19:31
operational pgp - draft

Operational PGP

This is a guide on how to email securely.

There are many guides on how to install and use PGP to encrypt email. This is not one of them. This is a guide on secure communication using email with PGP encryption. If you are not familiar with PGP, please read another guide first. If you are comfortable using PGP to encrypt and decrypt emails, this guide will raise your security to the next level.

#!/usr/bin/env python
# -*- coding: utf-8 -*-
import argparse
if __name__ == '__main__':
parser = argparse.ArgumentParser(description="""
I never freaking remember argparse syntax and the docs are so all over the place
that I need this for an example.
#!/usr/bin/env python
# Quick and dirty demonstration of CVE-2014-0160 by
# Jared Stafford (jspenguin@jspenguin.org)
# Modified so that it finds cookies
import sys
import struct
import socket
import time
import select
@moschlar
moschlar / awesomepythonpackages.md
Last active December 23, 2015 09:39
Collection of awesome Python packages. Just a personal notepad.
  • Arrow: better dates and times for Python
  • ftfy: fixes text for you
  • colors.py: Colors aren't that scary!
  • ordereddict: No need to include the ActiveState recipe anymore
  • argh: An unobtrusive argparse wrapper with natural syntax
  • billiard: Python multiprocessing fork with improvements and bugfixes
  • Unidecode: ASCII transliterations of Unicode text
  • anyjson: Wraps the best available JSON implementation available in a common interface
@dypsilon
dypsilon / frontendDevlopmentBookmarks.md
Last active March 3, 2026 20:57
A badass list of frontend development resources I collected over time.