Skip to content

Instantly share code, notes, and snippets.

View beriberikix's full-sized avatar
🐶
I have no idea what I'm doing

Jonathan Beri beriberikix

🐶
I have no idea what I'm doing
View GitHub Profile
@jed
jed / README.md
Created April 4, 2011 14:02
a small module for autorequiring. warning: MAGIC!

autorequire.js

Copyright (c) 2011 Jed Schmidt

a small module for auto-importing modules in node.js.

usage

require( "./autorequire" )
require.auto( <module-name> )
@adamzr
adamzr / mybot.js
Created May 25, 2011 23:12
My first node.js IRC bot
//
// My First IRC Bot
//
console.log("Bot Started...")
var irc = require('irc');
//For storing globals
var MYBOT = {};
//Channel to use
@fwielstra
fwielstra / api.js
Created June 14, 2011 14:46
An example NodeJS / Mongoose / Express application based on their respective tutorials
/* The API controller
Exports 3 methods:
* post - Creates a new thread
* list - Returns a list of threads
* show - Displays a thread and its posts
*/
var Thread = require('../models/thread.js');
var Post = require('../models/post.js');
@JasonGiedymin
JasonGiedymin / blog_cygwin_node_npm_err.sh
Created June 17, 2011 13:11
Fixing Node.JS NPM "--no-same-owner" errors in Cygwin.
# File is named as '.sh' for highlighting. Don't actually run this (hash bang removed).
#
# First of all, you should stop using cygwin and just use a VM or install linux.
# By continuing you acknowledge the fact your a nut. :-D
#
# If your having errors with Cygwin and NPM install packages such as:
# npm ERR! tar "-mvxpf" "-" "--no-same-owner"
#
# Do the following:
@jimbojsb
jimbojsb / gist:1630790
Created January 18, 2012 03:52
Code highlighting for Keynote presentations

Step 0:

Get Homebrew installed on your mac if you don't already have it

Step 1:

Install highlight. "brew install highlight". (This brings down Lua and Boost as well)

Step 2:

@errordeveloper
errordeveloper / README.md
Last active September 30, 2015 19:58
CodeSourcery ARM (2008q3) bare-metal toolchain on OS X

If you wish to compile the CS toolchain of version 2008q3 on OS X (Lion in my case, but should work on other versions), please do follow these instructions.

Firstly download the source tarball from Mentor site.

This comes with a particularly useless build script: arm-2008q3-66-arm-none-eabi.sh

@beriberikix
beriberikix / backbone-links.md
Created March 4, 2012 03:45
AWSUM Web Development Linkz

These instructions work for the Raspberry Pi running Raspbian (hard float) and create a hardware optimized version of NodeJS for the Raspberry PI, (and include a working install and NPM!!!):

  1. Install Raspbian - http://www.raspberrypi.org/downloads

  2. Install the necessary dependecies:

sudo apt-get install git-core build-essential

(If you just installed git then you need to administer your git identity first, else adding the patches below will fail!!!)

@ykessler
ykessler / timezones
Created August 14, 2012 14:50
JSON list of time zones (Based on Olson tz database)
[
{"group":"US (Common)",
"zones":[
{"value":"America/Puerto_Rico","name":"Puerto Rico (Atlantic)"},
{"value":"America/New_York","name":"New York (Eastern)"},
{"value":"America/Chicago","name":"Chicago (Central)"},
{"value":"America/Denver","name":"Denver (Mountain)"},
{"value":"America/Phoenix","name":"Phoenix (MST)"},
{"value":"America/Los_Angeles","name":"Los Angeles (Pacific)"},
{"value":"America/Anchorage","name":"Anchorage (Alaska)"},
@domenic
domenic / promises.md
Last active June 24, 2024 03:11
You're Missing the Point of Promises

This article has been given a more permanent home on my blog. Also, since it was first written, the development of the Promises/A+ specification has made the original emphasis on Promises/A seem somewhat outdated.

You're Missing the Point of Promises

Promises are a software abstraction that makes working with asynchronous operations much more pleasant. In the most basic definition, your code will move from continuation-passing style:

getTweetsFor("domenic", function (err, results) {
 // the rest of your code goes here.