Instantly share code, notes, and snippets.

View auto-tag.sieve
require "editheader";
require "envelope";
require "regex";
require "subaddress";
require "variables";
if envelope :matches :detail "to" "*" {
addheader "X-Label" "${1}";
View a602.diff
diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h
index 46d6b96..0473ba7 100644
--- a/Marlin/Configuration.h
+++ b/Marlin/Configuration.h
@@ -25,7 +25,8 @@
// This determines the communication speed of the printer
// This determines the communication speed of the printer
-#define BAUDRATE 250000
+//#define BAUDRATE 250000
View gist:e0fe324da305d6788d89
WITH ranked_days AS (
SELECT created, hchp, hchc,
rank() OVER(PARTITION BY date_trunc('day', created) ORDER BY created)
FROM teleinfo
SELECT date_trunc('day', created) AS created,
hchp - lag(hchp) OVER(ORDER BY created) AS HP,
hchc - lag(hchc) OVER(ORDER BY created) AS HC
FROM ranked_days
WHERE rank = 1;
View unicode.php
function √($x)
return pow($x, 0.5);
function ²($x)
if (is_array($x)) {
View a.php
function _valid_phone_number($phone)
$valid = false;
if (!empty($phone)) {
$phone_number = preg_replace('/\s/', '', $phone);
$prefix_length = 0;
if (substr($phone_number, 0, 3) == '+33') {
View a.php
function _is_siren($siren)
if (strlen($siren) != 9) {
return 1;
if (!is_numeric($siren)) {
return 2;

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url =

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

View Makefile-atmega328
SRC=$(wildcard *.c)
CPPFLAGS=-O2 -std=c99 -Wall -pedantic -Werror
View post-receive
mirror=`git remote | grep '^mirror$' | wc -l`
if [ $mirror -ne 0 ]
git push --mirror mirror
View FeatureContext.php
// ...
class FeatureContext extends MinkContext
* Looks for a table, then looks for a row that contains the given text.
* Once it finds the right row, it clicks a link in that row.