Skip to content

Instantly share code, notes, and snippets.

View hildjj's full-sized avatar

Joe Hildebrand hildjj

View GitHub Profile

Keybase proof

I hereby claim:

  • I am hildjj on github.
  • I am hildjj (https://keybase.io/hildjj) on keybase.
  • I have a public key whose fingerprint is 6BE0 0277 A430 7746 4A6D 6DE6 F60D 4C90 344F 5334

To claim this, I am signing this object:

@hildjj
hildjj / xmpp-server.diff
Created December 22, 2011 19:11
Patch to make openssl1 even more XMPP-friendly.
diff --git a/apps/s_client.c b/apps/s_client.c
index 34ad2ce..12df5bf 100644
--- a/apps/s_client.c
+++ b/apps/s_client.c
@@ -329,16 +329,18 @@ static void sc_usage(void)
BIO_printf(bio_err," -starttls prot - use the STARTTLS command before starting TLS\n");
BIO_printf(bio_err," for those protocols that support it, where\n");
BIO_printf(bio_err," 'prot' defines which one to assume. Currently,\n");
- BIO_printf(bio_err," only \"smtp\", \"pop3\", \"imap\", \"ftp\" and \"xmpp\"\n");
- BIO_printf(bio_err," are supported.\n");
@hildjj
hildjj / picks.py
Created March 12, 2012 16:38
Get random picks for the NCAA pool
import random
print [random.choice(["boring", "UPSET"]) for x in range(32+16+8+4+2+1)]
@hildjj
hildjj / data.html
Created March 23, 2012 07:52
Long-ish data URIs
<html>
<body>
<img src='data:image/png,%89PNG%0D%0A%1A%0A%00%00%00%0DIHDR%00%00%028%00%00%02%19%08%02%00%00%00%24%E7%D22%00%00%00%06bKGD%00%FF%00%FF%00%FF%A0%BD%A7%93%00%00%20%00IDATx%9C%EC%9Dy%7CS%C5%FA%FF%27%FB%BE7i%BA%17%28%94%B2%B4E%10%10%90%82%A5%AC%A2%02%A2%B5%08%CAW%40%10Y%95%CB%22%82lE%D4%B2%5C%F5%CA%A6%82%5CA%D1%0B%28%B2%94%1D%8A%D2%22R%29kKK%E9%DE%26i%9B%3Di%B6%F3%FBc.%F9%E5vI%D36%C9I%9Ay%FF%91%D7%C9%C993%CF%99%9C3%9F33%CF%3CC%C00%0C%20%10%08%04%02%E1%AB%10%F16%00%81%40%20%10%08g%20%A1B%20%10%08%84O%83%84%0A%81%40%20%10%3E%0D%12%2A%04%02%81%40%F84H%A8%10%08%04%02%E1%D3%20%A1B%20%10%08%84O%83%84%0A%81%40%20%10%3E%0D%12%2A%04%02%81%40%F84H%A8%10%08%04%02%E1%D3%20%A1B%20%10%08%84O%83%84%0A%81%40%20%10%3E%0D%12%2A%04%02%81%40%F84H%A8%10%08%04%02%E1%D3%20%A1B%20%10%08%84O%83%84%0A%D1%7E%EE%DD%BB%B7x%F1%E2%8A%8A%0A%BC%0DA%20%10%9D%19%24T%88%F6%B3z%F5%EA%1D%3Bv%EC%DE%BD%1BoC%10%08Dg%06%09%15%A2%FD%FC%F9%E7%9F%00%00%AB%D5%8A%B7%21%08%04%A23C%C6%DB%00%84%BFRSSS%5E%5E%DE%F1t%8E%1D%3Bf%B5Z%A7L%99%D2%F1%A4%9Cc%
@hildjj
hildjj / enum.h
Last active December 16, 2015 12:49
Generate enums and their string versions.
#ifndef ENUM_H
#define ENUM_H
#include <stddef.h>
#include <string.h>
#include <stdbool.h>
/* Entry points */
/* Define an enum, suitable for putting in a .h file */
@hildjj
hildjj / table.md
Last active December 17, 2015 03:39

``` boo bar ```

Syntax

=;:..
=====:_.
.=========.
.+===========.
.+===========++=.
-+=++======+=====
..=======+===+=+++.
.:===========+=+=+=++
;==========++=+=+=+====;:..
@hildjj
hildjj / foo.coffee
Created September 13, 2016 19:04
Make coffeescript that has been compiled to javascript run as shebang
#!/usr/bin/env coffee
`#!/usr/bin/env node
`
# The extra newline in the backticks is crucial.
# It keeps the semicolon that coffee-script adds from messing up the shebang.
# now compile with "coffee -bcs --no-header < foo.coffee > bin/foo"
# -b: bare
# -c: compile
# -s: stdio

Keybase proof

I hereby claim:

  • I am hildjj on github.
  • I am hildjj (https://keybase.io/hildjj) on keybase.
  • I have a public key ASDmI7_8nLpfDyYA-HkxEk4fyb0n0jLhl3kCLHS1U28bCwo

To claim this, I am signing this object:

@hildjj
hildjj / stylo.html
Created July 11, 2017 15:54
Test if stylo is enabled in your browser
<!DOCTYPE html>
<html>
<style>
body {
background: white;
}
#test:first-line {
color: white;
}
</style>