Skip to content

Instantly share code, notes, and snippets.

View atk's full-sized avatar
💻
implementing RFC 1925 #1

Alex Lohr atk

💻
implementing RFC 1925 #1
  • GoTo Group Inc.
  • Karlsruhe, Germany
View GitHub Profile
// golfed-down JS code to calculate the date of easter sunday for a given year
// based on the Gaussian Easter Formula (https://en.wikipedia.org/wiki/Computus)
function(y){var a=y%19,b=(19*a+24)%30,d=b+(2*(y%4)+4*(y%7)+6*b+5)%7;d-=d^35&(d^34|b^28|a<11)?0:7;y=new Date(y,2,22+d);return y}
function(
y // year input, later used as date object / return value
){
// calculate moon parameter
var a = y % 19,
// get the seed for the first full moon in spring
@atk
atk / LICENSE.txt
Last active August 29, 2015 14:24 — forked from 140bytes/LICENSE.txt
Check if node is child of a selection of nodes
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Alex Lohr (formerly Kloss) alexthkloss@web.de
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@atk
atk / LICENSE.txt
Last active August 29, 2015 14:22 — forked from 140bytes/LICENSE.txt
FlexWrap Support Detection
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2015 Alex Lohr (formerly Kloss) alexthkloss@web.de
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@atk
atk / LICENSE.txt
Last active August 29, 2015 14:21 — forked from 140bytes/LICENSE.txt
Number is Palindrome
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2015 Alex Lohr (formerly Kloss) <alexthkloss@web.de>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@atk
atk / lua2acei18n
Created November 14, 2014 07:13
Small snippet to create ACE i18n from WoW lua files in Chrome developer tools
// view raw lua file, open developer tools, select pre and run in console:
x={}; $0.innerHTML.replace(/L\["(.*?)"\]/g, function(c){ x[c] = true; }); L = []; for (var c in x) { L.push( c + ' = true') }; $0.innerHTML = L.join('\n');
@atk
atk / LICENSE.txt
Last active December 24, 2015 09:19 — forked from 140bytes/LICENSE.txt
iBAN helper functions
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2013 Alex Kloss <alexthkloss@web.de>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@atk
atk / LICENSE.txt
Last active February 1, 2018 13:56 — forked from 140bytes/LICENSE.txt
AJAX abstraction
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Alex Kloss <alexthkloss@web.de>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@atk
atk / LICENSE.txt
Last active December 18, 2015 09:49 — forked from 140bytes/LICENSE.txt
getElementsByClassName Shim
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2013 Alex Kloss <alexthkloss@web.de>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@atk
atk / LICENSE.txt
Last active December 18, 2015 02:39 — forked from 140bytes/LICENSE.txt
Offset
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2013 Alex Kloss <alexthkloss@web.de>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@atk
atk / LICENSE.txt
Last active December 11, 2015 06:59 — forked from 140bytes/LICENSE.txt
Decimal Points (for integer numbers)
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Alex Kloss <alexthkloss@web.de>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE