This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @param {import("@11ty/eleventy/src/UserConfig")} eleventyConfig | |
*/ | |
module.exports = (eleventyConfig) => { | |
return {}; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Inverted wikipedia | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description Invert, except images. Terrible for perf, probably... | |
// @author Thykkkz | |
// @match https://*.wikipedia.org/wiki/* | |
// @grant none | |
// ==/UserScript== |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Licensed under a CC0 1.0 Universal (CC0 1.0) Public Domain Dedication | |
// http://creativecommons.org/publicdomain/zero/1.0/ | |
// Pass in an array of numbers ranging from 0 to 20. | |
function playSparkline(notes) { | |
if (!window.AudioContext && !window.webkitAudioContext) { | |
return; | |
} | |
var playing = null; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# get total requests by status code | |
awk '{print $9}' /var/log/nginx/access.log | sort | uniq -c | sort -rn | |
# get top requesters by IP | |
awk '{print $1}' /var/log/nginx/access.log | sort | uniq -c | sort -rn | head | awk -v OFS='\t' '{"host " $2 | getline ip; print $0, ip}' | |
# get top requesters by user agent | |
awk -F'"' '{print $6}' /var/log/nginx/access.log | sort | uniq -c | sort -rn | head | |
# get top requests by URL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* bling.js */ | |
window.$ = document.querySelectorAll.bind(document); | |
Node.prototype.on = window.on = function (name, fn) { | |
this.addEventListener(name, fn); | |
} | |
NodeList.prototype.__proto__ = Array.prototype; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
# Licensed under a CC0 1.0 Universal (CC0 1.0) Public Domain Dedication | |
# http://creativecommons.org/publicdomain/zero/1.0/ | |
$mysite = 'https://adactio.com/'; // Change this to your website. | |
$token_endpoint = 'https://tokens.indieauth.com/token'; | |
$_HEADERS = array(); | |
foreach(getallheaders() as $name => $value) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RewriteEngine on | |
RewriteCond %{HTTP_REFERER} !^$ | |
# allowed domains, add as needed | |
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?google.com [NC] | |
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?christianheilmann.com [NC] | |
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?wait-till-i.com [NC] | |
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?mozilla.org [NC] | |
# search engines and social sites and stuff |