Skip to content

Instantly share code, notes, and snippets.

View rking's full-sized avatar

☈king rking

View GitHub Profile
(Latin) Code (Latin) Code
א A •- ל L •-••
ב B -••• מ M --
ג G --• נ N -•
ד D -•• ס C -•-•
ה O --- ע J •---
ו E • פ P •--•
ז Z --•• צ W •--
ח H •••• ק Q --•-
ט U ••- ר R •-•
#include <unistd.h>
#include <stdio.h>
#include <fcntl.h>
#include <linux/fb.h>
#include <sys/mman.h>
int main()
{
int fbfd = 0;
struct fb_var_screeninfo vinfo;
233615 <rking> Hi guys. I'm an async n00b. Is there a broad distinction between promises/futures/deferrables?
233623 <rking> And what do JS people use?
233628 <Norm_> niggler: thanks for the help
233643 <niggler> rking why not plain old callbacks?
233757 <DarkArgon> where do i find docs for the events in express? for example res.on('header')
234045 <rking> niggler: I'm not sure.
234137 <rking> niggler: What about stuffing them into an Array?
234209 <niggler> rking what are you trying to do? the common first-step is `async`
234227 <niggler> https://npmjs.org/package/async
234404 <rking> niggler: I'm not really sure. I'm just exploring ways of coding that are foreign to me.
#!/usr/bin/env ruby
require 'rspec'
def chop_at_crlf! data
data.sub! /(\r\n)(.*)/, '\1'
$2
end
describe 'thing' do
@rking
rking / Makefile
Created December 8, 2012 03:52
LaTeX Makefile
default: paper.pdf
evince paper.pdf &
%.pdf: %.tex
pdflatex $<
refs:
latex paper
bibtex paper
latex paper
latex paper
require 'spec_helper'
describe DriversController do
before :each do
@driver = FactoryGirl.create :driver
@another_driver = FactoryGirl.create :another_driver
end
describe 'GET edit' do
it 'assigns the requested driver as @driver' do
$hotpink: #f6f
$green: #6cc863
$mint: #c1ffc1
$darkmint: shade($mint, 20%)
$light-gray: tint(rgb(0,0,0), 70%)
$darker-gray: tint(rgb(0,0,0), 50%)
$newlink-color: $green
$hover-color: shade($hotpink, 25%)
class DriversController < ApplicationController
before_filter :authenticate_driver!
def index
end
# GET /drivers/1/edit
def edit
@driver = Driver.find params[:id]
end
import XMonad
--- Note: This requires xmonad-contrib (on Gentoo, at least)
import XMonad.Layout.ThreeColumns
import XMonad.Layout.Tabbed
import XMonad.Layout.Accordion
import XMonad.Layout.NoBorders
import System.Process
import System.Exit
+ cat cmd-output
% emerge xmonad-contrib ~@tsiyon
Password:
Calculating dependencies... done!
>>> Verifying ebuild manifests
>>> Emerging (1 of 1) x11-wm/xmonad-contrib-0.9
* xmonad-contrib-0.9.tar.gz RMD160 SHA1 SHA256 size ;-) ... [ ok ]
>>> Unpacking source...