Skip to content

Instantly share code, notes, and snippets.

crertel

  • Houston, TX.
Block or report user

Report or block crertel

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@crertel
crertel / janky_stream.js
Created Jul 2, 2019
Gross streaming server hack
View janky_stream.js
var http = require("http");
var express = require('express');
var fs = require("fs");
var app = express();
var files = [
[fs.readFileSync("./music/1.mp3"), 128 * 1024],
[fs.readFileSync("./music/2.mp3"), 64 * 1024],
];
@crertel
crertel / mastermind.el
Created May 21, 2019
Adventures in emacs-lisp doing a mastermind game
View mastermind.el
(require 'dash)
(setq kColors '( :red :green :blue :cyan :orange :yellow))
(defun make-random-color
(x)
"Picks a random color."
( nth (random ( length kColors) ) kColors ))
(defun make-sequence
@crertel
crertel / GeoChatClient
Created Oct 31, 2013
Simple example code for geo-based chatting.
View GeoChatClient
$(function(){
ws = new WebSocket("ws://localhost:8080");
ws.onmessage = function(evt) {
if ($('#chat tbody tr:first').length > 0){
$('#chat tbody tr:first').before('<tr><td>' + evt.data + '</td></tr>');
} else {
$('#chat tbody').append('<tr><td>' + evt.data + '</td></tr>');
}
};
You can’t perform that action at this time.