Skip to content

Instantly share code, notes, and snippets.

View pcornier's full-sized avatar

Pierco pcornier

View GitHub Profile
@jjmajava
jjmajava / mininum.txt
Last active April 5, 2024 07:56
Mininum Alpha - Minimal 3x4 pixel font for PuzzleScript
Title Mininum Alpha
Author Jere Majava
========
OBJECTS
========
background _
darkblue
player
@bradmontgomery
bradmontgomery / install-comodo-ssl-cert-for-nginx.rst
Last active April 1, 2024 11:21
Steps to install a Comodo PositiveSSL certificate with Nginx.

Setting up a SSL Cert from Comodo

I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.

These are the steps I went through to set up an SSL cert.

Purchase the cert

@caged
caged / svg-to-png.js
Created January 27, 2013 18:11
Convert SVG's to PNGs. This works OK if the SVG's styles are inline. The SVG element must contain an xmlns attribute. Webkit also requires you specify a font size on `text` elements.
var svg = document.getElementById('graph'),
xml = new XMLSerializer().serializeToString(svg),
data = "data:image/svg+xml;base64," + btoa(xml),
img = new Image()
img.setAttribute('src', data)
document.body.appendChild(img)
@scottferg
scottferg / ppu.go
Created September 9, 2012 21:58
Fubar PPU
package main
import (
"math"
)
const (
StatusSpriteOverflow = iota
StatusSprite0Hit
@shawndumas
shawndumas / soundex.js
Last active February 21, 2024 11:47
Soundex in JavaScript
var soundex = function (s) {
var a = s.toLowerCase().split(''),
f = a.shift(),
r = '',
codes = {
a: '', e: '', i: '', o: '', u: '',
b: 1, f: 1, p: 1, v: 1,
c: 2, g: 2, j: 2, k: 2, q: 2, s: 2, x: 2, z: 2,
d: 3, t: 3,
l: 4,