Skip to content

Instantly share code, notes, and snippets.

View olizilla's full-sized avatar

Oli Evans olizilla

View GitHub Profile
@andrew
andrew / confkick.md
Last active December 16, 2015 19:28

ConfKick

A community funded event sponsor

Description

ConfKick makes it possible for individuals to sponsor confernces and meetups focused, to begin with, on developer events.

A user can pledge an amount towards a conference/meetup/hackday as a token sponsorship, often a lot less than the price of a ticket to attend the event.

@max-mapper
max-mapper / readme.md
Created September 28, 2011 02:01
SLEEP - syncable.org

Your API does REST, but can it SLEEP?

SLEEP (Syncable Lightweight Event Emitting Persistence) is an emerging standard for distributed data sync using HTTP and JSON. A generalized version of CouchDB's much lauded built-in replication, SLEEP extends the REST architecture to define a way in which databases can offer syncable JSON APIs that foster open data innovation by allowing developers to replicate entire databases over the net.


SLEEP comes from the Apache CouchDB project which is now widely known for it's multi-master streaming HTTP + JSON replication. This is possible in part because of the CouchDB _changes feed, which is a particular API that lets you see if there have been any changes made to the database since last time you synchronized. CouchDB can efficiently implement the _changes feed because of one subtle difference between it and most other databases: it stores a history of all changes that happen to the database, including deletes.

If you synchronize data from a remote source and then the

@isaacs
isaacs / cla-response.md
Last active September 26, 2017 18:08
Occasionally people get upset at being asked to sign a standard Apache-style CLA to contribute code to a project. This is my response. Please feel free to copy/remix/etc any or all of it regarding your own project if you like, and let me know in the comments if you have any feedback, especially if something in here is unreasonable or incorrect. …

Caveat: I am not a lawyer.

I understand that asking you to give up ownership of something may sound weird or pushy. Legal documents are scary, and can be fraught with unintended consequences if they're entered into lightly. I hope that I can shed some light on why a project would do so, since I've been through this with several projects I maintain.

You need to permit sublicensing and re-licensing so that if you die, the project doesn't have to track down your heirs to sign off on any license changes. (Sadly not an unrealistic or particularly uncommon situation.) Remember, IP laws do change, sometimes in ways that change the spirit of licenses, or make them insufficient or suboptimal to protect the freedoms that they were designed to protect. That's why licenses like the BSD 2-clause and ISC exist, because earlier licenses were no longer ideal for OSS projects using them.

It is completely reasonable for the project to require that you agree to give them – actually give them, all the way, without res

From zero to microservice with 𝚫 now

The following guide will show you how to deploy a simple microservice written in JavaScript using 𝚫 now.

It uses Open Source tools that are widely available, tested and understood:

  • Node.JS
  • NPM
  • Express
@possibilities
possibilities / meteor-async.md
Created August 23, 2012 22:53
Meteor Async Guide

From Meteor's documentation:

In Meteor, your server code runs in a single thread per request, not in the asynchronous callback style typical of Node. We find the linear execution model a better fit for the typical server code in a Meteor application.

This guide serves as a mini-tour of tools, trix and patterns that can be used to run async code in Meteor.

Basic async

Sometimes we need to run async code in Meteor.methods. For this we create a Future to block until the async code has finished. This pattern can be seen all over Meteor's own codebase:

@peterhost
peterhost / node_debian_init.sh
Created November 25, 2010 11:41
Daemon init script for node.js based app/server (DEBIAN/UBUNTU)
#!/bin/sh
# ------------------------------------------------------------------------------
# SOME INFOS : fairly standard (debian) init script.
# Note that node doesn't create a PID file (hence --make-pidfile)
# has to be run in the background (hence --background)
# and NOT as root (hence --chuid)
#
# MORE INFOS : INIT SCRIPT http://www.debian.org/doc/debian-policy/ch-opersys.html#s-sysvinit
# INIT-INFO RULES http://wiki.debian.org/LSBInitScripts
# INSTALL/REMOVE http://www.debian-administration.org/articles/28
@jlong
jlong / uri.js
Created April 20, 2012 13:29
URI Parsing with Javascript
var parser = document.createElement('a');
parser.href = "http://example.com:3000/pathname/?search=test#hash";
parser.protocol; // => "http:"
parser.hostname; // => "example.com"
parser.port; // => "3000"
parser.pathname; // => "/pathname/"
parser.search; // => "?search=test"
parser.hash; // => "#hash"
parser.host; // => "example.com:3000"
@max-mapper
max-mapper / helloworld.js
Created November 27, 2012 06:55
droneduino
var serialport = require('node-serialport')
var sp = new serialport.SerialPort("/dev/ttyO3", {
parser: serialport.parsers.raw,
baud: 9600
})
sp.on('data', function(chunk) {
console.log(chunk.toString('hex'), chunk.toString(), chunk)
})
@mxstbr
mxstbr / Readme.md
Last active December 20, 2023 12:01
Enable tab completion for JSX with Emmet in Atom

Enable tab completion for JSX with Emmet in Atom

This guide assumes you have the emmet and language-babel packages already installed in Atom

Gif of the tab completion working

  1. Open the keymap.cson file by clicking on Atom -> Keymap… in the menu bar
  2. Add these lines of code to your keymap:
'atom-text-editor[data-grammar~="jsx"]:not([mini])':